Fix project name, links, rename the binaries (#11580)
* Fix project name, links, rename binary * Update util/version/Cargo.toml Co-Authored-By: David <dvdplm@gmail.com> * Update updater/Cargo.toml Co-Authored-By: David <dvdplm@gmail.com> * Update util/version/Cargo.toml Co-Authored-By: David <dvdplm@gmail.com> Co-authored-by: David <dvdplm@gmail.com>
This commit is contained in:
@@ -4,15 +4,15 @@ FROM ubuntu:xenial
|
||||
ARG VCS_REF
|
||||
ARG BUILD_DATE
|
||||
|
||||
LABEL io.parity.image.authors="devops-team@parity.io" \
|
||||
io.parity.image.vendor="Parity Technologies" \
|
||||
io.parity.image.title="parity/parity" \
|
||||
io.parity.image.description="Open Ethereum. The Fastest and most Advanced Ethereum Client." \
|
||||
io.parity.image.source="https://github.com/OpenEthereum/open-ethereum/blob/${VCS_REF}/\
|
||||
scripts/docker/hub/Dockerfile" \
|
||||
io.parity.image.documentation="https://wiki.parity.io/Parity-Ethereum" \
|
||||
io.parity.image.revision="${VCS_REF}" \
|
||||
io.parity.image.created="${BUILD_DATE}"
|
||||
LABEL openethereum.image.authors="devops-team@parity.io" \
|
||||
openethereum.image.vendor="OpenEthereum project" \
|
||||
openethereum.image.title="openethereum/openethereum" \
|
||||
openethereum.image.description="Fast and feature-rich multi-network Ethereum client." \
|
||||
openethereum.image.source="https://github.com/openethereum/openethereum/blob/${VCS_REF}/\
|
||||
scripts/docker/hub/Dockerfile" \
|
||||
openethereum.image.documentation="https://wiki.parity.io/Parity-Ethereum" \
|
||||
openethereum.image.revision="${VCS_REF}" \
|
||||
openethereum.image.created="${BUILD_DATE}"
|
||||
|
||||
# show backtraces
|
||||
ENV RUST_BACKTRACE 1
|
||||
@@ -21,28 +21,28 @@ ENV RUST_BACKTRACE 1
|
||||
RUN set -eux; \
|
||||
apt-get update; \
|
||||
apt-get install -y --no-install-recommends \
|
||||
file curl jq ca-certificates; \
|
||||
# apt cleanup
|
||||
file curl jq ca-certificates; \
|
||||
# apt cleanup
|
||||
apt-get autoremove -y; \
|
||||
apt-get clean; \
|
||||
update-ca-certificates; \
|
||||
update-ca-certificates; \
|
||||
rm -rf /tmp/* /var/tmp/* /var/lib/apt/lists/*; \
|
||||
# add user
|
||||
groupadd -g 1000 parity; \
|
||||
useradd -m -u 1000 -g parity -s /bin/sh parity
|
||||
# add user
|
||||
groupadd -g 1000 openethereum; \
|
||||
useradd -m -u 1000 -g openethereum -s /bin/sh openethereum
|
||||
|
||||
WORKDIR /home/parity
|
||||
WORKDIR /home/openethereum
|
||||
|
||||
# add open-ethereum binary to docker image
|
||||
COPY artifacts/x86_64-unknown-linux-gnu/parity /bin/parity
|
||||
# add openethereum binary to docker image
|
||||
COPY artifacts/x86_64-unknown-linux-gnu/openethereum /bin/openethereum
|
||||
COPY tools/check_sync.sh /check_sync.sh
|
||||
|
||||
# switch to user parity here
|
||||
USER parity
|
||||
# switch to user openethereum here
|
||||
USER openethereum
|
||||
|
||||
# check if executable works in this container
|
||||
RUN parity --version
|
||||
RUN openethereum --version
|
||||
|
||||
EXPOSE 5001 8080 8082 8083 8545 8546 8180 30303/tcp 30303/udp
|
||||
|
||||
ENTRYPOINT ["/bin/parity"]
|
||||
ENTRYPOINT ["/bin/openethereum"]
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
#!/bin/bash
|
||||
# checks if parity has a fully synced blockchain
|
||||
# checks if OpenEthereum has a fully synced blockchain
|
||||
|
||||
ETH_SYNCING=$(curl -X POST --data '{"jsonrpc":"2.0","method":"eth_syncing","params":[],"id":1}' http://localhost:8545 -H 'Content-Type: application/json')
|
||||
RESULT=$(echo "$ETH_SYNCING" | jq -r .result)
|
||||
|
||||
if [ "$RESULT" == "false" ]; then
|
||||
echo "Parity is ready to start accepting traffic"
|
||||
echo "OpenEthereum is ready to start accepting traffic"
|
||||
exit 0
|
||||
else
|
||||
echo "Parity is still syncing the blockchain"
|
||||
echo "OpenEthereum is still syncing the blockchain"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
@@ -4,53 +4,53 @@ set -e # fail on any error
|
||||
|
||||
VERSION=$(cat ./tools/VERSION)
|
||||
TRACK=$(cat ./tools/TRACK)
|
||||
echo "Open Ethereum version = ${VERSION}"
|
||||
echo "Open Ethereum track = ${TRACK}"
|
||||
echo "OpenEthereum version = ${VERSION}"
|
||||
echo "OpenEthereum track = ${TRACK}"
|
||||
|
||||
test "$Docker_Hub_User_Parity" -a "$Docker_Hub_Pass_Parity" \
|
||||
test "$Docker_Hub_User_OpenEthereum" -a "$Docker_Hub_Pass_OpenEthereum" \
|
||||
|| ( echo "no docker credentials provided"; exit 1 )
|
||||
docker login -u "$Docker_Hub_User_Parity" -p "$Docker_Hub_Pass_Parity"
|
||||
docker login -u "$Docker_Hub_User_OpenEthereum" -p "$Docker_Hub_Pass_OpenEthereum"
|
||||
echo "__________Docker info__________"
|
||||
docker info
|
||||
|
||||
# we stopped pushing nightlies to dockerhub, will push to own registry prb.
|
||||
case "${SCHEDULE_TAG:-${CI_COMMIT_REF_NAME}}" in
|
||||
"$SCHEDULE_TAG")
|
||||
echo "Docker TAG - 'parity/parity:${SCHEDULE_TAG}'";
|
||||
echo "Docker TAG - 'openethereum/openethereum:${SCHEDULE_TAG}'";
|
||||
docker build --no-cache \
|
||||
--build-arg VCS_REF="${CI_COMMIT_SHA}" \
|
||||
--build-arg BUILD_DATE="$(date -u '+%Y-%m-%dT%H:%M:%SZ')" \
|
||||
--tag "parity/parity:${SCHEDULE_TAG}" \
|
||||
--tag "openethereum/openethereum:${SCHEDULE_TAG}" \
|
||||
--file tools/Dockerfile .;
|
||||
docker push "parity/parity:${SCHEDULE_TAG}";;
|
||||
docker push "openethereum/openethereum:${SCHEDULE_TAG}";;
|
||||
"stable")
|
||||
echo "Docker TAGs - 'parity/parity:${VERSION}-${CI_COMMIT_REF_NAME}', 'parity/parity:stable'";
|
||||
echo "Docker TAGs - 'openethereum/openethereum:${VERSION}-${CI_COMMIT_REF_NAME}', 'openethereum/openethereum:stable'";
|
||||
docker build --no-cache \
|
||||
--build-arg VCS_REF="${CI_COMMIT_SHA}" \
|
||||
--build-arg BUILD_DATE="$(date -u '+%Y-%m-%dT%H:%M:%SZ')" \
|
||||
--tag "parity/parity:${VERSION}-${CI_COMMIT_REF_NAME}" \
|
||||
--tag "parity/parity:latest" \
|
||||
--tag "parity/parity:stable" \
|
||||
--tag "openethereum/openethereum:${VERSION}-${CI_COMMIT_REF_NAME}" \
|
||||
--tag "openethereum/openethereum:latest" \
|
||||
--tag "openethereum/openethereum:stable" \
|
||||
--file tools/Dockerfile .;
|
||||
docker push "parity/parity:${VERSION}-${CI_COMMIT_REF_NAME}";
|
||||
docker push "parity/parity:stable";
|
||||
docker push "parity/parity:latest";;
|
||||
docker push "openethereum/openethereum:${VERSION}-${CI_COMMIT_REF_NAME}";
|
||||
docker push "openethereum/openethereum:stable";
|
||||
docker push "openethereum/openethereum:latest";;
|
||||
v[0-9]*.[0-9]*)
|
||||
echo "Docker TAG - 'parity/parity:${VERSION}-${TRACK}'"
|
||||
echo "Docker TAG - 'openethereum/openethereum:${VERSION}-${TRACK}'"
|
||||
docker build --no-cache \
|
||||
--build-arg VCS_REF="${CI_COMMIT_SHA}" \
|
||||
--build-arg BUILD_DATE="$(date -u '+%Y-%m-%dT%H:%M:%SZ')" \
|
||||
--tag "parity/parity:${VERSION}-${TRACK}" \
|
||||
--tag "openethereum/openethereum:${VERSION}-${TRACK}" \
|
||||
--file tools/Dockerfile .;
|
||||
docker push "parity/parity:${VERSION}-${TRACK}";;
|
||||
docker push "openethereum/openethereum:${VERSION}-${TRACK}";;
|
||||
*)
|
||||
echo "Docker TAG - 'parity/parity:${VERSION}-${CI_COMMIT_REF_NAME}'"
|
||||
echo "Docker TAG - 'openethereum/openethereum:${VERSION}-${CI_COMMIT_REF_NAME}'"
|
||||
docker build --no-cache \
|
||||
--build-arg VCS_REF="${CI_COMMIT_SHA}" \
|
||||
--build-arg BUILD_DATE="$(date -u '+%Y-%m-%dT%H:%M:%SZ')" \
|
||||
--tag "parity/parity:${VERSION}-${CI_COMMIT_REF_NAME}" \
|
||||
--tag "openethereum/openethereum:${VERSION}-${CI_COMMIT_REF_NAME}" \
|
||||
--file tools/Dockerfile .;
|
||||
docker push "parity/parity:${VERSION}-${CI_COMMIT_REF_NAME}";;
|
||||
docker push "openethereum/openethereum:${VERSION}-${CI_COMMIT_REF_NAME}";;
|
||||
esac
|
||||
|
||||
docker logout
|
||||
|
||||
Reference in New Issue
Block a user