From 15c89a8fff7ec9ac672d5053da4576a358627343 Mon Sep 17 00:00:00 2001 From: "Denis S. Soldatov aka General-Beck" Date: Wed, 3 May 2017 17:31:56 +0300 Subject: [PATCH] add docker build for hub.docker.com/r/parity --- .gitlab-ci.yml | 12 ++++++++---- scripts/docker-build.sh | 1 - 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 375735545..9a36d165b 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -488,10 +488,10 @@ windows: - aws configure set aws_access_key_id %s3_key% - aws configure set aws_secret_access_key %s3_secret% - echo %CI_BUILD_REF_NAME% - - echo %CI_BUILD_REF_NAME% | findstr /R "master" >nul 2>&1 && set S3_BUCKET=builds-parity-published || set S3_BUCKET=builds-parity - - echo %CI_BUILD_REF_NAME% | findstr /R "beta" >nul 2>&1 && set S3_BUCKET=builds-parity-published || set S3_BUCKET=builds-parity - - echo %CI_BUILD_REF_NAME% | findstr /R "stable" >nul 2>&1 && set S3_BUCKET=builds-parity-published || set S3_BUCKET=builds-parity - - echo %CI_BUILD_REF_NAME% | findstr /R "nightly" >nul 2>&1 && set S3_BUCKET=builds-parity-published || set S3_BUCKET=builds-parity + - echo %CI_BUILD_REF_NAME% | findstr /R "master" >nul 2>&1 && set S3_BUCKET=builds-parity-published|| set S3_BUCKET=builds-parity + - echo %CI_BUILD_REF_NAME% | findstr /R "beta" >nul 2>&1 && set S3_BUCKET=builds-parity-published|| set S3_BUCKET=builds-parity + - echo %CI_BUILD_REF_NAME% | findstr /R "stable" >nul 2>&1 && set S3_BUCKET=builds-parity-published|| set S3_BUCKET=builds-parity + - echo %CI_BUILD_REF_NAME% | findstr /R "nightly" >nul 2>&1 && set S3_BUCKET=builds-parity-published|| set S3_BUCKET=builds-parity - echo %S3_BUCKET% - aws s3 rm --recursive s3://%S3_BUCKET%/%CI_BUILD_REF_NAME%/x86_64-pc-windows-msvc - aws s3api put-object --bucket %S3_BUCKET% --key %CI_BUILD_REF_NAME%/x86_64-pc-windows-msvc/parity.exe --body target\release\parity.exe @@ -523,6 +523,10 @@ docker-build: - if [ "$CI_BUILD_REF_NAME" == "beta-release" ]; then DOCKER_TAG="latest"; else DOCKER_TAG=$CI_BUILD_REF_NAME; fi - docker login -u $Docker_Hub_User -p $Docker_Hub_Pass - sh scripts/docker-build.sh $DOCKER_TAG + - docker logout + - docker login -u $Docker_Hub_User_Parity -p $Docker_Hub_Pass_Parity + - sh scripts/docker-build.sh $DOCKER_TAG + - docker logout tags: - docker test-coverage: diff --git a/scripts/docker-build.sh b/scripts/docker-build.sh index 01bffc48f..70bc85912 100644 --- a/scripts/docker-build.sh +++ b/scripts/docker-build.sh @@ -2,4 +2,3 @@ cd docker/hub 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