fix: CI: build release profile bin and publish
ci/woodpecker/push/woodpecker Pipeline is pending Details

This commit is contained in:
Aravinth Manivannan 2022-12-19 14:53:46 +05:30
parent 4b1535848f
commit b93373e96b
Signed by: realaravinth
GPG Key ID: AD9F0F08E855ED88
3 changed files with 24 additions and 16 deletions

View File

@ -5,7 +5,7 @@ pipeline:
- DATABASE_URL=postgres://postgres:password@database:5432/postgres
commands:
- curl -fsSL https://deb.nodesource.com/setup_16.x | bash - &&\
- apt update && apt-get -y --no-install-recommends install nodejs
- apt update && apt-get -y --no-install-recommends install nodejs tar gpg curl wget
- rustup component add rustfmt
- rustup component add clippy
# rewrite conducotr configuration
@ -14,6 +14,7 @@ pipeline:
- make migrate
- make lint
- make test
- make release
build_docker_img:
image: plugins/docker
@ -35,23 +36,26 @@ pipeline:
repo: realaravinth/librepages
tags: latest
build_publisher_docker_img:
image: plugins/docker
when:
event: [push, tag, deployment]
settings:
dry_run: true
dockerfile: scripts/publish-bins-docker
purge: false
repo: realaravinth/librepages-publisher
tags: latest
# build_publisher_docker_img:
# image: plugins/docker
# when:
# event: [push, tag, deployment]
# settings:
# dry_run: true
# dockerfile: scripts/publish-bins-docker
# purge: false
# repo: realaravinth/librepages-publisher
# tags: latest
#
publish_bins:
image: realaravinth/librepages-publisher
image: rust
when:
event: [push, tag, deployment]
commands:
- /src/scripts/bin-publish.sh publish master latest $DUMBSERVE_PASSWORD
- apt update
- apt-get -y --no-install-recommends install gpg tar curl wget
- echo -n "$RELEASE_BOT_GPG_SIGNING_KEY" | gpg --batch --import --pinentry-mode loopback
- scripts/bin-publish.sh publish master latest $DUMBSERVE_PASSWORD
secrets: [RELEASE_BOT_GPG_SIGNING_KEY, DUMBSERVE_PASSWORD, GPG_PASSWORD]
services:

View File

@ -41,7 +41,7 @@ get_bin(){
#container_id=$(docker create $DOCKER_IMG)
#docker cp $container_id:/usr/local/bin/pages $TARGET_DIR/
#docker rm -v $container_id
cp /src/librepages $TARGET_DIR
cp target/release/librepages $TARGET_DIR
}
copy() {

View File

@ -7,4 +7,8 @@ RUN apt-get -y --no-install-recommends install gpg tar curl wget
WORKDIR /src
COPY --from=base /usr/local/bin/librepages .
COPY . .
RUN find
ARG RELEASE_BOT_GPG_SIGNING_KEY
RUN echo -n "$RELEASE_BOT_GPG_SIGNING_KEY"
RUN echo -n "$RELEASE_BOT_GPG_SIGNING_KEY" | gpg --batch --import --pinentry-mode loopback
env GPG_PASSWORD=$GPG_PASSWORD
RUN /src/scripts/bin-publish.sh publish master latest $DUMBSERVE_PASSWORD