From 5aba214276482314dbc965e994bffdc139ecc462 Mon Sep 17 00:00:00 2001 From: 5chdn <5chdn@users.noreply.github.com> Date: Wed, 13 Jun 2018 12:49:46 +0200 Subject: [PATCH 1/9] scripts: remove rpm packages --- scripts/gitlab-build.sh | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/scripts/gitlab-build.sh b/scripts/gitlab-build.sh index 08640e2300d..9ebbf60b64a 100755 --- a/scripts/gitlab-build.sh +++ b/scripts/gitlab-build.sh @@ -123,20 +123,6 @@ make_deb () { dpkg-deb -b deb "parity_"$VER"_"$IDENT"_"$ARC".deb" $SHA256_BIN "parity_"$VER"_"$IDENT"_"$ARC".deb" > "parity_"$VER"_"$IDENT"_"$ARC".deb.sha256" } -make_rpm () { - rm -rf /install - mkdir -p /install/usr/bin - cp target/$PLATFORM/release/parity /install/usr/bin - cp target/$PLATFORM/release/parity-evm /install/usr/bin/parity-evm - cp target/$PLATFORM/release/ethstore /install/usr/bin/ethstore - cp target/$PLATFORM/release/ethkey /install/usr/bin/ethkey - cp target/$PLATFORM/release/whisper /install/usr/bin/whisper - - rm -rf "parity-"$VER"-1."$ARC".rpm" || true - fpm -s dir -t rpm -n parity -v $VER --epoch 1 --license GPLv3 -d openssl --provides parity --url https://parity.io --vendor "Parity Technologies" -a x86_64 -m "" --description "Ethereum network client by Parity Technologies" -C /install/ - cp "parity-"$VER"-1."$ARC".rpm" "parity_"$VER"_"$IDENT"_"$ARC".rpm" - $SHA256_BIN "parity_"$VER"_"$IDENT"_"$ARC".rpm" > "parity_"$VER"_"$IDENT"_"$ARC".rpm.sha256" -} sign_exe () { ./sign.cmd $keyfile $certpass "target/$PLATFORM/release/parity.exe" } @@ -206,11 +192,9 @@ case $BUILD_PLATFORM in ;; x86_64-unknown-centos-gnu) STRIP_BIN="strip" - EXT="rpm" build strip_binaries calculate_checksums - make_rpm make_archive push_binaries ;; From 3b81610638b6587196221ab01c0fe374e927549a Mon Sep 17 00:00:00 2001 From: 5chdn <5chdn@users.noreply.github.com> Date: Wed, 13 Jun 2018 12:52:17 +0200 Subject: [PATCH 2/9] scripts: remove deb packages --- scripts/deb-build.sh | 34 ----------------------------- scripts/gitlab-build.sh | 48 ----------------------------------------- 2 files changed, 82 deletions(-) delete mode 100755 scripts/deb-build.sh diff --git a/scripts/deb-build.sh b/scripts/deb-build.sh deleted file mode 100755 index 5682e2c293b..00000000000 --- a/scripts/deb-build.sh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/bash - -set -e # fail on any error -set -u # treat unset variables as error -rm -rf deb -#create DEBIAN files -mkdir -p deb/usr/bin/ -mkdir -p deb/DEBIAN -#create copyright, docs, compat -cp LICENSE deb/DEBIAN/copyright -echo "https://github.com/paritytech/parity/wiki" >> deb/DEBIAN/docs -echo "8" >> deb/DEBIAN/compat -#create control file -control=deb/DEBIAN/control -echo "Package: parity" >> $control -version=`grep -m 1 version Cargo.toml | awk '{print $3}' | tr -d '"' | tr -d "\n"` -echo "Version: $version" >> $control -echo "Source: parity" >> $control -echo "Section: science" >> $control -echo "Priority: extra" >> $control -echo "Maintainer: Parity Technologies " >> $control -echo "Build-Depends: debhelper (>=9)" >> $control -echo "Standards-Version: 3.9.5" >> $control -echo "Homepage: https://parity.io" >> $control -echo "Vcs-Git: git://github.com/paritytech/parity.git" >> $control -echo "Vcs-Browser: https://github.com/paritytech/parity" >> $control -echo "Architecture: $1" >> $control -echo "Depends: libssl1.0.0 (>=1.0.0)" >> $control -echo "Description: Ethereum network client by Parity Technologies" >> $control -size=`du deb/|awk 'END {print $1}'` -echo "Installed-Size: $size" >> $control -#build .deb package - -exit diff --git a/scripts/gitlab-build.sh b/scripts/gitlab-build.sh index 9ebbf60b64a..5bd512f938f 100755 --- a/scripts/gitlab-build.sh +++ b/scripts/gitlab-build.sh @@ -87,42 +87,6 @@ calculate_checksums () { $SHA256_BIN target/$PLATFORM/release/ethkey$S3WIN > ethkey$S3WIN.sha256 $SHA256_BIN target/$PLATFORM/release/whisper$S3WIN > whisper$S3WIN.sha256 } -make_deb () { - rm -rf deb - echo "create DEBIAN files" - mkdir -p deb/usr/bin/ - mkdir -p deb/DEBIAN - echo "create copyright, docs, compat" - cp LICENSE deb/DEBIAN/copyright - echo "https://github.com/paritytech/parity/wiki" >> deb/DEBIAN/docs - echo "8" >> deb/DEBIAN/compat - echo "create control file" - control=deb/DEBIAN/control - echo "Package: parity" >> $control - echo "Version: $VER" >> $control - echo "Source: parity" >> $control - echo "Section: science" >> $control - echo "Priority: extra" >> $control - echo "Maintainer: Parity Technologies " >> $control - echo "Build-Depends: debhelper (>=9)" >> $control - echo "Standards-Version: 3.9.5" >> $control - echo "Homepage: https://parity.io" >> $control - echo "Vcs-Git: git://github.com/paritytech/parity.git" >> $control - echo "Vcs-Browser: https://github.com/paritytech/parity" >> $control - echo "Architecture: $ARC" >> $control - echo "Depends: $LIBSSL" >> $control - echo "Description: Ethereum network client by Parity Technologies" >> $control - size=`du deb/|awk 'END {print $1}'` - echo "Installed-Size: $size" >> $control - echo "build .deb package" - cp target/$PLATFORM/release/parity deb/usr/bin/parity - cp target/$PLATFORM/release/parity-evm deb/usr/bin/parity-evm - cp target/$PLATFORM/release/ethstore deb/usr/bin/ethstore - cp target/$PLATFORM/release/ethkey deb/usr/bin/ethkey - cp target/$PLATFORM/release/whisper deb/usr/bin/whisper - dpkg-deb -b deb "parity_"$VER"_"$IDENT"_"$ARC".deb" - $SHA256_BIN "parity_"$VER"_"$IDENT"_"$ARC".deb" > "parity_"$VER"_"$IDENT"_"$ARC".deb.sha256" -} sign_exe () { ./sign.cmd $keyfile $certpass "target/$PLATFORM/release/parity.exe" } @@ -169,24 +133,20 @@ case $BUILD_PLATFORM in #set strip bin STRIP_BIN="strip" #package extention - EXT="deb" build strip_binaries calculate_checksums - make_deb make_archive push_binaries updater_push_release ;; x86_64-unknown-debian-gnu) STRIP_BIN="strip" - EXT="deb" LIBSSL="libssl1.1 (>=1.1.0)" echo "Use libssl1.1 (>=1.1.0) for Debian builds" build strip_binaries calculate_checksums - make_deb make_archive push_binaries ;; @@ -200,45 +160,37 @@ case $BUILD_PLATFORM in ;; i686-unknown-linux-gnu) STRIP_BIN="strip" - EXT="deb" set_env build strip_binaries calculate_checksums - make_deb make_archive push_binaries ;; armv7-unknown-linux-gnueabihf) STRIP_BIN="arm-linux-gnueabihf-strip" - EXT="deb" set_env build strip_binaries calculate_checksums - make_deb make_archive push_binaries ;; arm-unknown-linux-gnueabihf) STRIP_BIN="arm-linux-gnueabihf-strip" - EXT="deb" set_env build strip_binaries calculate_checksums - make_deb make_archive push_binaries ;; aarch64-unknown-linux-gnu) STRIP_BIN="aarch64-linux-gnu-strip" - EXT="deb" set_env build strip_binaries calculate_checksums - make_deb make_archive push_binaries ;; From 8fe766f2f0f879e5a2dd5b2ae1330dd7a818f44d Mon Sep 17 00:00:00 2001 From: 5chdn <5chdn@users.noreply.github.com> Date: Wed, 13 Jun 2018 12:54:28 +0200 Subject: [PATCH 3/9] scripts: remove unused zip archives --- scripts/gitlab-build.sh | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/scripts/gitlab-build.sh b/scripts/gitlab-build.sh index 5bd512f938f..7a9fab4122c 100755 --- a/scripts/gitlab-build.sh +++ b/scripts/gitlab-build.sh @@ -112,11 +112,6 @@ push_binaries () { aws s3api put-object --bucket $S3_BUCKET --key $CI_BUILD_REF_NAME/$BUILD_PLATFORM/whisper$S3WIN --body target/$PLATFORM/release/whisper$S3WIN aws s3api put-object --bucket $S3_BUCKET --key $CI_BUILD_REF_NAME/$BUILD_PLATFORM/whisper$S3WIN.sha256 --body whisper$S3WIN.sha256 } -make_archive () { - echo "add artifacts to archive" - rm -rf parity.zip - zip -r parity.zip target/$PLATFORM/release/parity$S3WIN target/$PLATFORM/release/parity-evm$S3WIN target/$PLATFORM/release/ethstore$S3WIN target/$PLATFORM/release/ethkey$S3WIN target/$PLATFORM/release/whisper$S3WIN parity$S3WIN.sha256 parity-evm$S3WIN.sha256 ethstore$S3WIN.sha256 ethkey$S3WIN.sha256 whisper$S3WIN.sha256 -} updater_push_release () { echo "push release" @@ -136,7 +131,6 @@ case $BUILD_PLATFORM in build strip_binaries calculate_checksums - make_archive push_binaries updater_push_release ;; @@ -147,7 +141,6 @@ case $BUILD_PLATFORM in build strip_binaries calculate_checksums - make_archive push_binaries ;; x86_64-unknown-centos-gnu) @@ -155,7 +148,6 @@ case $BUILD_PLATFORM in build strip_binaries calculate_checksums - make_archive push_binaries ;; i686-unknown-linux-gnu) @@ -164,7 +156,6 @@ case $BUILD_PLATFORM in build strip_binaries calculate_checksums - make_archive push_binaries ;; armv7-unknown-linux-gnueabihf) @@ -173,7 +164,6 @@ case $BUILD_PLATFORM in build strip_binaries calculate_checksums - make_archive push_binaries ;; arm-unknown-linux-gnueabihf) @@ -182,7 +172,6 @@ case $BUILD_PLATFORM in build strip_binaries calculate_checksums - make_archive push_binaries ;; aarch64-unknown-linux-gnu) @@ -191,7 +180,6 @@ case $BUILD_PLATFORM in build strip_binaries calculate_checksums - make_archive push_binaries ;; x86_64-apple-darwin) @@ -200,7 +188,6 @@ case $BUILD_PLATFORM in build strip_binaries calculate_checksums - make_archive push_binaries updater_push_release ;; @@ -242,7 +229,6 @@ case $BUILD_PLATFORM in build sign_exe calculate_checksums - make_archive push_binaries updater_push_release esac From 650638f2b637a9fa3c8f2f1477f40083160a204c Mon Sep 17 00:00:00 2001 From: 5chdn <5chdn@users.noreply.github.com> Date: Wed, 13 Jun 2018 12:57:27 +0200 Subject: [PATCH 4/9] scripts: remove unused ssl references --- .gitlab-ci.yml | 2 -- scripts/gitlab-build.sh | 3 --- 2 files changed, 5 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index d4add41721b..c56cb21d1ea 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -7,7 +7,6 @@ variables: RUSTFLAGS: "" CARGOFLAGS: "" CI_SERVER_NAME: "GitLab CI" - LIBSSL: "libssl1.0.0 (>=1.0.0)" cache: key: "$CI_BUILD_STAGE-$CI_BUILD_REF_NAME" paths: @@ -40,7 +39,6 @@ linux-debian: - stable - triggers script: - - export LIBSSL="libssl1.1 (>=1.1.0)" - scripts/gitlab-build.sh x86_64-unknown-debian-gnu x86_64-unknown-linux-gnu amd64 gcc g++ debian tags: - rust-debian diff --git a/scripts/gitlab-build.sh b/scripts/gitlab-build.sh index 7a9fab4122c..d9961fbfd02 100755 --- a/scripts/gitlab-build.sh +++ b/scripts/gitlab-build.sh @@ -17,7 +17,6 @@ echo "Build identifier: " $IDENT echo "Cargo target: " $PLATFORM echo "CC&CXX flags: " $CC ", " $CXX echo "Architecture: " $ARC -echo "Libssl version: " $LIBSSL echo "Parity version: " $VER echo "Branch: " $CI_BUILD_REF_NAME echo "--------------------" @@ -136,8 +135,6 @@ case $BUILD_PLATFORM in ;; x86_64-unknown-debian-gnu) STRIP_BIN="strip" - LIBSSL="libssl1.1 (>=1.1.0)" - echo "Use libssl1.1 (>=1.1.0) for Debian builds" build strip_binaries calculate_checksums From 33b0a78ebbd6e89ade93d7dcf87856f3f2405f0c Mon Sep 17 00:00:00 2001 From: 5chdn <5chdn@users.noreply.github.com> Date: Wed, 13 Jun 2018 13:00:41 +0200 Subject: [PATCH 5/9] scripts: remove debian and centos pipelines --- .gitlab-ci.yml | 36 ++---------------------------------- scripts/gitlab-build.sh | 14 -------------- 2 files changed, 2 insertions(+), 48 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index c56cb21d1ea..49ff9ba6abd 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -12,7 +12,7 @@ cache: paths: - target/ untracked: true -linux-ubuntu: +linux-amd64: stage: build image: parity/rust:gitlab-ci only: @@ -30,38 +30,6 @@ linux-ubuntu: paths: - parity.zip name: "stable-x86_64-unknown-linux-gnu_parity" -linux-debian: - stage: build - image: parity/rust-debian:gitlab-ci - only: - - beta - - tags - - stable - - triggers - script: - - scripts/gitlab-build.sh x86_64-unknown-debian-gnu x86_64-unknown-linux-gnu amd64 gcc g++ debian - tags: - - rust-debian - artifacts: - paths: - - parity.zip - name: "stable-x86_64-unknown-debian-gnu_parity" -linux-centos: - stage: build - image: parity/rust-centos:gitlab-ci - only: - - beta - - tags - - stable - - triggers - script: - - scripts/gitlab-build.sh x86_64-unknown-centos-gnu x86_64-unknown-linux-gnu x86_64 gcc g++ centos - tags: - - rust-centos - artifacts: - paths: - - parity.zip - name: "x86_64-unknown-centos-gnu_parity" linux-i686: stage: build image: parity/rust-i686:gitlab-ci @@ -96,7 +64,7 @@ linux-armv7: - parity.zip name: "armv7_unknown_linux_gnueabihf_parity" allow_failure: true -linux-arm: +linux-armhf: stage: build image: parity/rust-arm:gitlab-ci only: diff --git a/scripts/gitlab-build.sh b/scripts/gitlab-build.sh index d9961fbfd02..7a31a457d61 100755 --- a/scripts/gitlab-build.sh +++ b/scripts/gitlab-build.sh @@ -133,20 +133,6 @@ case $BUILD_PLATFORM in push_binaries updater_push_release ;; - x86_64-unknown-debian-gnu) - STRIP_BIN="strip" - build - strip_binaries - calculate_checksums - push_binaries - ;; - x86_64-unknown-centos-gnu) - STRIP_BIN="strip" - build - strip_binaries - calculate_checksums - push_binaries - ;; i686-unknown-linux-gnu) STRIP_BIN="strip" set_env From 1863609c2a3bda6b323168a227e26b6c7fe8890f Mon Sep 17 00:00:00 2001 From: 5chdn <5chdn@users.noreply.github.com> Date: Wed, 13 Jun 2018 13:06:51 +0200 Subject: [PATCH 6/9] scripts: rename ubuntu to generic linux --- .gitlab-ci.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 49ff9ba6abd..8f2304e5a8f 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -23,7 +23,7 @@ linux-amd64: script: - rustup default stable # ARGUMENTS: 1. BUILD_PLATFORM (target for binaries) 2. PLATFORM (target for cargo) 3. ARC (architecture) 4. & 5. CC & CXX flags 6. binary identifier - - scripts/gitlab-build.sh x86_64-unknown-linux-gnu x86_64-unknown-linux-gnu amd64 gcc g++ ubuntu + - scripts/gitlab-build.sh x86_64-unknown-linux-gnu x86_64-unknown-linux-gnu amd64 gcc g++ linux tags: - rust-stable artifacts: @@ -39,7 +39,7 @@ linux-i686: - stable - triggers script: - - scripts/gitlab-build.sh i686-unknown-linux-gnu i686-unknown-linux-gnu i386 gcc g++ ubuntu + - scripts/gitlab-build.sh i686-unknown-linux-gnu i686-unknown-linux-gnu i386 gcc g++ linux tags: - rust-i686 artifacts: @@ -56,7 +56,7 @@ linux-armv7: - stable - triggers script: - - scripts/gitlab-build.sh armv7-unknown-linux-gnueabihf armv7-unknown-linux-gnueabihf armhf arm-linux-gnueabihf-gcc arm-linux-gnueabihf-g++ ubuntu + - scripts/gitlab-build.sh armv7-unknown-linux-gnueabihf armv7-unknown-linux-gnueabihf armhf arm-linux-gnueabihf-gcc arm-linux-gnueabihf-g++ linux tags: - rust-arm artifacts: @@ -73,7 +73,7 @@ linux-armhf: - stable - triggers script: - - scripts/gitlab-build.sh arm-unknown-linux-gnueabihf arm-unknown-linux-gnueabihf armhf arm-linux-gnueabihf-gcc arm-linux-gnueabihf-g++ ubuntu + - scripts/gitlab-build.sh arm-unknown-linux-gnueabihf arm-unknown-linux-gnueabihf armhf arm-linux-gnueabihf-gcc arm-linux-gnueabihf-g++ linux tags: - rust-arm artifacts: @@ -90,7 +90,7 @@ linux-aarch64: - stable - triggers script: - - scripts/gitlab-build.sh aarch64-unknown-linux-gnu aarch64-unknown-linux-gnu arm64 aarch64-linux-gnu-gcc aarch64-linux-gnu-g++ ubuntu + - scripts/gitlab-build.sh aarch64-unknown-linux-gnu aarch64-unknown-linux-gnu arm64 aarch64-linux-gnu-gcc aarch64-linux-gnu-g++ linux tags: - rust-arm artifacts: From 7701cfcf4f27f0d0793877b6f8e11a08223a986f Mon Sep 17 00:00:00 2001 From: 5chdn <5chdn@users.noreply.github.com> Date: Wed, 13 Jun 2018 13:14:15 +0200 Subject: [PATCH 7/9] scripts: restore archives used in gitlab artifacts --- scripts/gitlab-build.sh | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/scripts/gitlab-build.sh b/scripts/gitlab-build.sh index 7a31a457d61..db219abb1d1 100755 --- a/scripts/gitlab-build.sh +++ b/scripts/gitlab-build.sh @@ -112,6 +112,12 @@ push_binaries () { aws s3api put-object --bucket $S3_BUCKET --key $CI_BUILD_REF_NAME/$BUILD_PLATFORM/whisper$S3WIN.sha256 --body whisper$S3WIN.sha256 } +make_archive () { + echo "add artifacts to archive" + rm -rf parity.zip + zip -r parity.zip target/$PLATFORM/release/parity$S3WIN target/$PLATFORM/release/parity-evm$S3WIN target/$PLATFORM/release/ethstore$S3WIN target/$PLATFORM/release/ethkey$S3WIN target/$PLATFORM/release/whisper$S3WIN parity$S3WIN.sha256 parity-evm$S3WIN.sha256 ethstore$S3WIN.sha256 ethkey$S3WIN.sha256 whisper$S3WIN.sha256 +} + updater_push_release () { echo "push release" @@ -130,6 +136,7 @@ case $BUILD_PLATFORM in build strip_binaries calculate_checksums + make_archive push_binaries updater_push_release ;; @@ -139,6 +146,7 @@ case $BUILD_PLATFORM in build strip_binaries calculate_checksums + make_archive push_binaries ;; armv7-unknown-linux-gnueabihf) @@ -147,6 +155,7 @@ case $BUILD_PLATFORM in build strip_binaries calculate_checksums + make_archive push_binaries ;; arm-unknown-linux-gnueabihf) @@ -155,6 +164,7 @@ case $BUILD_PLATFORM in build strip_binaries calculate_checksums + make_archive push_binaries ;; aarch64-unknown-linux-gnu) @@ -163,6 +173,7 @@ case $BUILD_PLATFORM in build strip_binaries calculate_checksums + make_archive push_binaries ;; x86_64-apple-darwin) @@ -171,6 +182,7 @@ case $BUILD_PLATFORM in build strip_binaries calculate_checksums + make_archive push_binaries updater_push_release ;; @@ -212,6 +224,7 @@ case $BUILD_PLATFORM in build sign_exe calculate_checksums + make_archive push_binaries updater_push_release esac From f0accf2cadc281eaa8b55c18c4c1df2c7404e3d6 Mon Sep 17 00:00:00 2001 From: 5chdn <5chdn@users.noreply.github.com> Date: Wed, 13 Jun 2018 13:15:43 +0200 Subject: [PATCH 8/9] scripts: init submodules for full test suite --- test.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/test.sh b/test.sh index 9bb527b7083..9e273c7492a 100755 --- a/test.sh +++ b/test.sh @@ -56,4 +56,5 @@ cd parity-clib-example && \ # Running tests echo "________Running Parity Full Test Suite________" +git submodule update --init --recursive cargo test -j 8 $OPTIONS --features "$FEATURES" --all $1 From 23802c3cdd280ff30b7a32359e3ce6dc34177601 Mon Sep 17 00:00:00 2001 From: 5chdn <5chdn@users.noreply.github.com> Date: Wed, 13 Jun 2018 13:18:18 +0200 Subject: [PATCH 9/9] scripts: do not publish master builds, only nightly, stable, beta --- scripts/gitlab-build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/gitlab-build.sh b/scripts/gitlab-build.sh index db219abb1d1..5e272f6216c 100755 --- a/scripts/gitlab-build.sh +++ b/scripts/gitlab-build.sh @@ -93,7 +93,7 @@ push_binaries () { echo "Push binaries to AWS S3" aws configure set aws_access_key_id $s3_key aws configure set aws_secret_access_key $s3_secret - if [[ "$CI_BUILD_REF_NAME" = "master" || "$CI_BUILD_REF_NAME" = "beta" || "$CI_BUILD_REF_NAME" = "stable" || "$CI_BUILD_REF_NAME" = "nightly" ]]; + if [[ "$CI_BUILD_REF_NAME" = "beta" || "$CI_BUILD_REF_NAME" = "stable" || "$CI_BUILD_REF_NAME" = "nightly" ]]; then export S3_BUCKET=builds-parity-published; else