From 82547a0cb36db0aa7d64487b909322305f7904a2 Mon Sep 17 00:00:00 2001 From: William Blevins Date: Mon, 14 Jun 2021 19:33:55 -0400 Subject: [PATCH 1/3] Add linux package artifact tests to pipeline. --- .cicd/generate-pipeline.sh | 55 ++++++++++++++++++++++++++++++++++++++ .cicd/test-package.sh | 35 ++++++++++++++++++++++++ 2 files changed, 90 insertions(+) create mode 100755 .cicd/test-package.sh diff --git a/.cicd/generate-pipeline.sh b/.cicd/generate-pipeline.sh index ab2d53471a4..70a0a912c5f 100755 --- a/.cicd/generate-pipeline.sh +++ b/.cicd/generate-pipeline.sh @@ -566,6 +566,33 @@ cat < $SCRIPT_NAME </dev/null) ]]; then # debian family + UPDATE='apt-get update' + echo "$ \$UPDATE" + eval \$UPDATE + echo '--- :minidisc: Install EOSIO' + INSTALL="apt-get install -y /eos/*.deb" + echo "$ \$INSTALL" + eval \$INSTALL +elif [[ \$(yum --version 2>/dev/null) ]]; then # RHEL family + UPDATE='yum check-update || :' + echo "$ \$UPDATE" + eval \$UPDATE + INSTALL="yum install -y /eos/*.rpm" + echo "$ \$INSTALL" + eval \$INSTALL +else + echo 'ERROR: Package manager not detected!' + exit 3 +fi + +nodeos --full-version +EOL + +chmod +x $SCRIPT_NAME + +docker pull $IMAGE +docker run --rm -v "$(pwd):/eos" -w '/eos' -it $IMAGE ./$SCRIPT_NAME From fd2dfc5a59d10640ced01fbea8a9146bb53f5bd7 Mon Sep 17 00:00:00 2001 From: William Blevins Date: Tue, 15 Jun 2021 18:45:42 -0400 Subject: [PATCH 2/3] Break out subscript since the repo is available. --- .cicd/test-package.run.sh | 25 +++++++++++++++++++++++++ .cicd/test-package.sh | 32 ++------------------------------ 2 files changed, 27 insertions(+), 30 deletions(-) create mode 100755 .cicd/test-package.run.sh diff --git a/.cicd/test-package.run.sh b/.cicd/test-package.run.sh new file mode 100755 index 00000000000..37f09fa29cf --- /dev/null +++ b/.cicd/test-package.run.sh @@ -0,0 +1,25 @@ +#!/bin/bash +set -eu + +echo '+++ :minidisc: Installing EOSIO' + +if [[ $(apt-get --version 2>/dev/null) ]]; then # debian family + UPDATE='apt-get update' + echo "$ $UPDATE" + eval $UPDATE + INSTALL="apt-get install -y /eos/*.deb" + echo "$ $INSTALL" + eval $INSTALL +elif [[ $(yum --version 2>/dev/null) ]]; then # RHEL family + UPDATE='yum check-update || :' + echo "$ $UPDATE" + eval $UPDATE + INSTALL="yum install -y /eos/*.rpm" + echo "$ $INSTALL" + eval $INSTALL +else + echo 'ERROR: Package manager not detected!' + exit 3 +fi + +nodeos --full-version diff --git a/.cicd/test-package.sh b/.cicd/test-package.sh index f8af427d79e..039f939fa45 100755 --- a/.cicd/test-package.sh +++ b/.cicd/test-package.sh @@ -1,35 +1,7 @@ #!/bin/bash - -SCRIPT_NAME='test-package.gen.sh' - -cat > $SCRIPT_NAME </dev/null) ]]; then # debian family - UPDATE='apt-get update' - echo "$ \$UPDATE" - eval \$UPDATE - echo '--- :minidisc: Install EOSIO' - INSTALL="apt-get install -y /eos/*.deb" - echo "$ \$INSTALL" - eval \$INSTALL -elif [[ \$(yum --version 2>/dev/null) ]]; then # RHEL family - UPDATE='yum check-update || :' - echo "$ \$UPDATE" - eval \$UPDATE - INSTALL="yum install -y /eos/*.rpm" - echo "$ \$INSTALL" - eval \$INSTALL -else - echo 'ERROR: Package manager not detected!' - exit 3 -fi - -nodeos --full-version -EOL - -chmod +x $SCRIPT_NAME +echo '--- :docker: Selecting Container' docker pull $IMAGE -docker run --rm -v "$(pwd):/eos" -w '/eos' -it $IMAGE ./$SCRIPT_NAME +docker run --rm -v "$(pwd):/eos" -w '/eos' -it $IMAGE ./.cicd/test-package.run.sh From 8bd101fb7db7a314d51c3690bc58d1f3cc5be44f Mon Sep 17 00:00:00 2001 From: William Blevins Date: Wed, 16 Jun 2021 12:41:06 -0400 Subject: [PATCH 3/3] Update test package steps to match supported OS for develop. --- .cicd/generate-pipeline.sh | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/.cicd/generate-pipeline.sh b/.cicd/generate-pipeline.sh index 70a0a912c5f..69c927df442 100755 --- a/.cicd/generate-pipeline.sh +++ b/.cicd/generate-pipeline.sh @@ -607,19 +607,19 @@ cat <