Skip to content
Snippets Groups Projects
Unverified Commit 4252e488 authored by Alexandru Gheorghe's avatar Alexandru Gheorghe Committed by GitHub
Browse files

ci: fix worker binaries could not be found (#1198)


* ci: fix worker binaries could not be found

Signed-off-by: default avatarAlexandru Gheorghe <alexandru.gheorghe@parity.io>

* Add missing bits

Signed-off-by: default avatarAlexandru Gheorghe <alexandru.gheorghe@parity.io>

* Fix malus build

Signed-off-by: default avatarAlexandru Gheorghe <alexandru.gheorghe@parity.io>

---------

Signed-off-by: default avatarAlexandru Gheorghe <alexandru.gheorghe@parity.io>
Co-authored-by: default avatarAlexander Samusev <41779041+alvicsam@users.noreply.github.com>
parent 70ab64bd
No related merge requests found
Pipeline #384725 canceled with stages
in 54 minutes and 50 seconds
......@@ -18,11 +18,13 @@ build-linux-stable:
# Ensure we run the UI tests.
RUN_UI_TESTS: 1
script:
- time cargo build --locked --profile testnet --features pyroscope,fast-runtime --bin polkadot
- time cargo build --locked --profile testnet --features pyroscope,fast-runtime --bin polkadot --bin polkadot-prepare-worker --bin polkadot-execute-worker
# pack artifacts
- mkdir -p ./artifacts
- VERSION="${CI_COMMIT_REF_NAME}" # will be tag or branch name
- mv ./target/testnet/polkadot ./artifacts/.
- mv ./target/testnet/polkadot-prepare-worker ./artifacts/.
- mv ./target/testnet/polkadot-execute-worker ./artifacts/.
- pushd artifacts
- sha256sum polkadot | tee polkadot.sha256
- shasum -c polkadot.sha256
......@@ -64,10 +66,12 @@ build-malus:
- .run-immediately
- .collect-artifacts
script:
- time cargo build --locked --profile testnet --verbose -p polkadot-test-malus
- time cargo build --locked --profile testnet --verbose -p polkadot-test-malus --bin malus --bin polkadot-prepare-worker --bin polkadot-execute-worker
# pack artifacts
- mkdir -p ./artifacts
- mv ./target/testnet/malus ./artifacts/.
- mv ./target/testnet/polkadot-execute-worker ./artifacts/.
- mv ./target/testnet/polkadot-prepare-worker ./artifacts/.
- echo -n "${CI_COMMIT_REF_NAME}" > ./artifacts/VERSION
- echo -n "${CI_COMMIT_REF_NAME}-${CI_COMMIT_SHORT_SHA}" > ./artifacts/EXTRATAG
- echo "polkadot-test-malus = $(cat ./artifacts/VERSION) (EXTRATAG = $(cat ./artifacts/EXTRATAG))"
......
......@@ -39,7 +39,7 @@ RUN apt-get update && \
# add adder-collator binary to docker image
COPY ./artifacts/malus /usr/local/bin
COPY ./artifacts/malus ./artifacts/polkadot-execute-worker ./artifacts/polkadot-prepare-worker /usr/local/bin
USER nonroot
......
......@@ -32,13 +32,15 @@ RUN apt-get update && \
chown -R polkadot:polkadot /data && \
ln -s /data /polkadot/.local/share/polkadot
# add polkadot binary to docker image
COPY ./artifacts/polkadot /usr/local/bin
# add polkadot binaries to docker image
COPY ./artifacts/polkadot ./artifacts/polkadot-execute-worker ./artifacts/polkadot-prepare-worker /usr/local/bin
USER polkadot
# check if executable works in this container
RUN /usr/local/bin/polkadot --version
RUN /usr/local/bin/polkadot-execute-worker --version
RUN /usr/local/bin/polkadot-prepare-worker --version
EXPOSE 30333 9933 9944
VOLUME ["/polkadot"]
......
......@@ -44,6 +44,8 @@ USER polkadot
# check if executable works in this container
RUN /usr/bin/polkadot --version
RUN /usr/local/bin/polkadot-execute-worker --version
RUN /usr/local/bin/polkadot-prepare-worker --version
EXPOSE 30333 9933 9944
VOLUME ["/polkadot"]
......
......@@ -159,6 +159,16 @@ assets = [
"/usr/bin/",
"755",
],
[
"target/release/polkadot-prepare-worker",
"/usr/lib/polkadot/",
"755"
],
[
"target/release/polkadot-execute-worker",
"/usr/lib/polkadot/",
"755"
],
[
"scripts/packaging/polkadot.service",
"/lib/systemd/system/",
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment