From 6c58232036c505a3ec203a26a3c33e1578bdf227 Mon Sep 17 00:00:00 2001 From: "Denis S. Soldatov aka General-Beck" Date: Fri, 21 Jul 2017 18:31:29 +0300 Subject: [PATCH] fix docker build in stable & add Aura test (reverted from commit d7eb3cb51ef6fed23e135b3aecc5fe1c8de66a8e) --- .gitlab-ci.yml | 4 ---- scripts/aura-test.sh | 25 ------------------------- scripts/docker-build.sh | 8 +++----- 3 files changed, 3 insertions(+), 34 deletions(-) delete mode 100755 scripts/aura-test.sh diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index d93e2a785..0b13bb66f 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -526,15 +526,12 @@ windows: docker-build: stage: build only: - - beta - - stable - tags - triggers before_script: - docker info script: - if [ "$CI_BUILD_REF_NAME" == "beta-release" ]; then DOCKER_TAG="latest"; else DOCKER_TAG=$CI_BUILD_REF_NAME; fi - - echo "Tag:" $DOCKER_TAG - docker login -u $Docker_Hub_User_Parity -p $Docker_Hub_Pass_Parity - sh scripts/docker-build.sh $DOCKER_TAG - docker logout @@ -574,7 +571,6 @@ test-rust-stable: script: - export RUST_BACKTRACE=1 - if [ $RUST_FILES_MODIFIED -eq 0 ]; then echo "Skipping Rust tests since no Rust files modified."; else ./test.sh $CARGOFLAGS; fi - - if [ $CI_BUILD_REF_NAME =~ ^(beta|stable|nightly)$ ]; then sh scripts/aura-test.sh; fi tags: - rust - rust-stable diff --git a/scripts/aura-test.sh b/scripts/aura-test.sh deleted file mode 100755 index 43fa65736..000000000 --- a/scripts/aura-test.sh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/bash -rm -rf parity-import-tests/ -cargo build -j $(nproc) --release --features final -git clone https://github.com/paritytech/parity-import-tests -cp target/release/parity parity-import-tests/aura/parity -cd parity-import-tests/aura -./parity -v -echo "Start Aura test" -./parity import blocks.rlp --chain chain.json -if [ $? -eq 0 ] -then - echo "Import test passed" -else - echo "Import test failed" >&2 - exit 1 -fi -./parity restore snap --chain chain.json --log-file restore.log -if [ $? -eq 0 ] -then - echo "Restore test passed" -else - echo "Restore test failed" >&2 - exit 1 -fi -echo "Aura test complete" diff --git a/scripts/docker-build.sh b/scripts/docker-build.sh index 1f3987401..294e172eb 100644 --- a/scripts/docker-build.sh +++ b/scripts/docker-build.sh @@ -1,8 +1,6 @@ #!/bin/bash cd docker/hub -DOCKER_BUILD_TAG=$1 -echo "Docker build tag: " $DOCKER_BUILD_TAG -docker build --build-arg BUILD_TAG=$DOCKER_BUILD_TAG --no-cache=true --tag parity/parity:$DOCKER_BUILD_TAG . -docker run -it parity/parity:$DOCKER_BUILD_TAG -v -docker push parity/parity:$DOCKER_BUILD_TAG +if [ "$1" == "latest" ]; then DOCKER_BUILD_TAG="beta-release"; fi +docker build --build-arg BUILD_TAG=$DOCKER_BUILD_TAG --no-cache=true --tag ethcore/parity:$1 . +docker push ethcore/parity:$1