-
Notifications
You must be signed in to change notification settings - Fork 707
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add yaml config for azure pipelines fix service discovery integration test to work without changes to /etc/hosts Change-Id: Ib6003511949d5e956cb246e8dfd2139a9e849780 Signed-off-by: andrew-coleman <andrew_coleman@uk.ibm.com>
- Loading branch information
1 parent
923cc16
commit d0a66e5
Showing
4 changed files
with
107 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
# Maven | ||
# Build your Java project and run tests with Apache Maven. | ||
# Add steps that analyze code, save build artifacts, deploy, and more: | ||
# https://docs.microsoft.com/azure/devops/pipelines/languages/java | ||
|
||
trigger: | ||
- master | ||
|
||
pool: | ||
vmImage: 'ubuntu-latest' | ||
|
||
jobs: | ||
- job: test | ||
steps: | ||
- script: | | ||
set -eo pipefail | ||
export ORG_HYPERLEDGER_FABRIC_SDKTEST_FIXVERSION=2.0 | ||
export ORG_HYPERLEDGER_FABRIC_SDKTEST_VERSION=2.0.0 | ||
export IMAGE_TAG_FABRIC=2.0 | ||
export IMAGE_TAG_FABRIC_CA=2.0 | ||
######################## | ||
# Pull nodenev image from nexus and re-tag to hyperledger/fabric-nodeenv | ||
####################### | ||
docker pull nexus3.hyperledger.org:10001/hyperledger/fabric-nodeenv:amd64-2.0.0-stable | ||
docker tag nexus3.hyperledger.org:10001/hyperledger/fabric-nodeenv:amd64-2.0.0-stable hyperledger/fabric-nodeenv:amd64-latest | ||
docker tag nexus3.hyperledger.org:10001/hyperledger/fabric-nodeenv:amd64-2.0.0-stable hyperledger/fabric-nodeenv | ||
docker pull nexus3.hyperledger.org:10001/hyperledger/fabric-javaenv:amd64-2.0.0-stable | ||
docker tag nexus3.hyperledger.org:10001/hyperledger/fabric-javaenv:amd64-2.0.0-stable hyperledger/fabric-javaenv:amd64-latest | ||
docker tag nexus3.hyperledger.org:10001/hyperledger/fabric-javaenv:amd64-2.0.0-stable hyperledger/fabric-javaenv | ||
########## | ||
docker images | grep hyperledger/fabric-nodeenv || true | ||
source ./src/test/fabric_test_commitlevel.sh | ||
./src/test/pull_images.sh | ||
WD=$PWD GOPATH=$PWD/src/test/fixture ./src/test/cirun.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
#!/bin/bash -e | ||
set -o pipefail | ||
|
||
echo "======== PULL DOCKER IMAGES ========" | ||
|
||
########################################################## | ||
# Pull and Tag the fabric and fabric-ca images from Nexus | ||
########################################################## | ||
echo "Fetching images from Nexus" | ||
NEXUS_URL=nexus3.hyperledger.org:10001 | ||
ORG_NAME="hyperledger/fabric" | ||
|
||
VERSION=2.0.0 | ||
ARCH="amd64" | ||
: ${STABLE_VERSION:=$VERSION-stable} | ||
STABLE_TAG=$ARCH-$STABLE_VERSION | ||
MASTER_TAG=$ARCH-master | ||
|
||
echo "---------> STABLE_VERSION:" $STABLE_VERSION | ||
|
||
dockerTag() { | ||
for IMAGES in peer orderer ca ca orderer baseos ccenv javaenv nodeenv tools; do | ||
echo "Images: $IMAGES" | ||
echo | ||
docker pull $NEXUS_URL/$ORG_NAME-$IMAGES:$STABLE_TAG | ||
if [ $? != 0 ]; then | ||
echo "FAILED: Docker Pull Failed on $IMAGES" | ||
exit 1 | ||
fi | ||
docker tag $NEXUS_URL/$ORG_NAME-$IMAGES:$STABLE_TAG $ORG_NAME-$IMAGES | ||
docker tag $NEXUS_URL/$ORG_NAME-$IMAGES:$STABLE_TAG $ORG_NAME-$IMAGES:$MASTER_TAG | ||
echo "$ORG_NAME-$IMAGES:$MASTER_TAG" | ||
echo "Deleting Nexus docker images: $IMAGES" | ||
docker rmi -f $NEXUS_URL/$ORG_NAME-$IMAGES:$STABLE_TAG | ||
done | ||
} | ||
|
||
dockerTag2() { | ||
for IMAGES in baseos ccenv javaenv nodeenv; do | ||
echo "Images: $IMAGES" | ||
echo | ||
docker pull $NEXUS_URL/$ORG_NAME-$IMAGES:$STABLE_TAG | ||
if [ $? != 0 ]; then | ||
echo "FAILED: Docker Pull Failed on $IMAGES" | ||
exit 1 | ||
fi | ||
docker tag $NEXUS_URL/$ORG_NAME-$IMAGES:$STABLE_TAG $ORG_NAME-$IMAGES | ||
docker tag $NEXUS_URL/$ORG_NAME-$IMAGES:$STABLE_TAG $ORG_NAME-$IMAGES:$VERSION | ||
echo "$ORG_NAME-$IMAGES:$VERSION" | ||
echo "Deleting Nexus docker images: $IMAGES" | ||
docker rmi -f $NEXUS_URL/$ORG_NAME-$IMAGES:$STABLE_TAG | ||
done | ||
} | ||
|
||
dockerTag | ||
dockerTag2 | ||
|
||
echo | ||
docker images | grep "hyperledger*" | ||
echo |