Skip to content

Commit 00da4e2

Browse files
authored
Change pipeline storage account (#541)
* update pipeline * update pipeline * k8s version 1.17 in test * update pipeline timeout
1 parent 38dc38e commit 00da4e2

File tree

7 files changed

+18
-18
lines changed

7 files changed

+18
-18
lines changed

.pipelines/e2e-job-template.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ parameters:
99
jobs:
1010
- job: ${{ parameters.name }}
1111
dependsOn: unit_tests
12-
timeoutInMinutes: 90
12+
timeoutInMinutes: 120
1313
pool:
1414
name: Networking-ContainerNetworking
1515
demands: agent.os -equals Linux
@@ -22,6 +22,7 @@ jobs:
2222
acnPath: "$(GOPATH)/src/github.com/Azure/azure-container-networking"
2323
Tag: $[ dependencies.unit_tests.outputs['EnvironmentalVariables.Tag'] ]
2424
CommitHash: $[ dependencies.unit_tests.outputs['EnvironmentalVariables.CommitHash'] ]
25+
StorageID: $[ dependencies.unit_tests.outputs['EnvironmentalVariables.StorageID'] ]
2526
CLEANUP_ON_EXIT: true
2627
CLEANUP_IF_FAIL: true
2728
steps:

.pipelines/e2e-step-template.yaml

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ steps:
1313
mkdir -p '$(GOBIN)'
1414
mkdir -p '$(GOPATH)/pkg'
1515
mkdir -p '$(modulePath)'
16-
1716
go get github.com/onsi/ginkgo/ginkgo
1817
go get github.com/onsi/gomega/...
1918
@@ -40,14 +39,11 @@ steps:
4039
4140
# download binary
4241
wget https://github.com/Azure/aks-engine/releases/download/$aksEVersion/aks-engine-$aksEVersion-linux-amd64.tar.gz
43-
4442
mkdir ./bin
4543
4644
#extract binary
4745
tar -zxvf aks-engine-$aksEVersion-linux-amd64.tar.gz -C bin
48-
4946
mv ./bin/aks-engine-*/* ./bin/
50-
5147
echo '##vso[task.prependpath]$(GOBIN)'
5248
echo '##vso[task.prependpath]$(GOROOT)/bin'
5349
name: "GoEnv"
@@ -63,7 +59,7 @@ steps:
6359

6460
- bash: |
6561
ls -lah
66-
export CNI_URL=https://$(ARTIFACT_STORAGE).blob.core.windows.net/acn-$(CommitHash)/azure-vnet-cni-${{ parameters.clusterDefinitionCniBuildOS }}-amd64-$(Tag)${{ parameters.clusterDefinitionCniBuildExt }}
62+
export CNI_URL=https://$(ARTIFACT_STORAGE).blob.core.windows.net/acn-$(StorageID)/azure-vnet-cni-${{ parameters.clusterDefinitionCniBuildOS }}-amd64-$(Tag)${{ parameters.clusterDefinitionCniBuildExt }}
6763
export CNI_TYPE=${{ parameters.clusterDefinitionCniTypeKey }}
6864
echo CNI type is $CNI_TYPE
6965
cat '${{ parameters.clusterDefinition }}' | jq --arg cnikey $CNI_TYPE --arg cniurl $CNI_URL '.properties.orchestratorProfile.kubernetesConfig[$cnikey]= $cniurl' > '${{ parameters.clusterDefinition }}'.tmp #
@@ -73,8 +69,8 @@ steps:
7369
echo "Running E2E tests against a cluster built with the following API model:"
7470
cat '${{ parameters.clusterDefinition }}'
7571
cp ${{ parameters.clusterDefinition }} clusterDefinition.json
76-
curl -L https://dl.k8s.io/v1.16.0/kubernetes-client-linux-amd64.tar.gz | tar xvzf -
77-
sudo cp kubernetes/client/bin/kubectl /usr/local/bin/kubectl
72+
curl -L https://dl.k8s.io/v1.17.4/kubernetes-client-linux-amd64.tar.gz | tar xvzf -
73+
sudo cp kubernetes/client/bin/kubectl /usr/local/bin/kubectl
7874
sudo cp kubernetes/client/bin/kubectl /usr/local/bin/k
7975
displayName: Configure AKS-Engine
8076
workingDirectory: "$(modulePath)"

.pipelines/pipeline.yaml

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,8 @@ stages:
5252
displayName: "Set up the Go environment"
5353
5454
- script: |
55+
BUILD_NUMBER=$(Build.BuildNumber)
56+
echo "##vso[task.setvariable variable=StorageID;isOutput=true]$(echo ${BUILD_NUMBER//./-})"
5557
echo "##vso[task.setvariable variable=CommitHash;isOutput=true]$(git rev-parse HEAD)"
5658
echo "##vso[task.setvariable variable=Tag;isOutput=true]$(git describe --tags --always --dirty)"
5759
export BRANCH=$(Build.SourceBranchName)
@@ -168,9 +170,9 @@ stages:
168170
azureSubscription: $(ARTIFACT_SUBSCRIPTION)
169171
scriptLocation: "inlineScript"
170172
inlineScript: |
171-
echo Creating storage container with name acn-$(EnvironmentalVariables.CommitHash) and account name $(STORAGE_ACCOUNT_NAME)
172-
az storage container create -n acn-$(EnvironmentalVariables.CommitHash) --account-name $(STORAGE_ACCOUNT_NAME) --public-access container
173-
az storage blob upload-batch -d acn-$(EnvironmentalVariables.CommitHash) -s ./output/ --account-name $(STORAGE_ACCOUNT_NAME)
173+
echo Creating storage container with name acn-$(EnvironmentalVariables.StorageID) and account name $(STORAGE_ACCOUNT_NAME)
174+
az storage container create -n acn-$(EnvironmentalVariables.StorageID) --account-name $(STORAGE_ACCOUNT_NAME) --public-access container
175+
az storage blob upload-batch -d acn-$(EnvironmentalVariables.StorageID) -s ./output/ --account-name $(STORAGE_ACCOUNT_NAME)
174176
workingDirectory: "$(modulePath)"
175177
displayName: Create artifact storage container
176178
condition: succeeded()
@@ -226,8 +228,9 @@ stages:
226228
azureSubscription: $(ARTIFACT_SUBSCRIPTION)
227229
scriptLocation: "inlineScript"
228230
inlineScript: |
229-
export CommitHash=$(git rev-parse HEAD)
230-
echo Deleting storage container with name acn-$CommitHash and account name $(STORAGE_ACCOUNT_NAME)
231-
az storage container delete -n acn-$CommitHash --account-name $(STORAGE_ACCOUNT_NAME)
231+
BUILD_NUMBER=$(Build.BuildNumber)
232+
BUILD_NUMBER=${BUILD_NUMBER//./-}
233+
echo Deleting storage container with name acn-$BUILD_NUMBER and account name $(STORAGE_ACCOUNT_NAME)
234+
az storage container delete -n acn-$BUILD_NUMBER --account-name $(STORAGE_ACCOUNT_NAME)
232235
workingDirectory: "$(modulePath)"
233236
displayName: Cleanup remote Azure storage container

test/e2e/kubernetes/cniLinux1604.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"properties": {
44
"orchestratorProfile": {
55
"orchestratorType": "Kubernetes",
6-
"orchestratorRelease": "1.16",
6+
"orchestratorRelease": "1.17",
77
"kubernetesConfig": {
88
"networkPlugin": "azure",
99
"networkPolicy": "azure",

test/e2e/kubernetes/cniLinux1804.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"properties": {
44
"orchestratorProfile": {
55
"orchestratorType": "Kubernetes",
6-
"orchestratorRelease": "1.16",
6+
"orchestratorRelease": "1.17",
77
"kubernetesConfig": {
88
"networkPlugin": "azure",
99
"networkPolicy": "azure",

test/e2e/kubernetes/cniWindows1809.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"properties": {
44
"orchestratorProfile": {
55
"orchestratorType": "Kubernetes",
6-
"orchestratorRelease": "1.16",
6+
"orchestratorRelease": "1.17",
77
"kubernetesConfig": {
88
"networkPlugin": "azure",
99
"networkPolicy": "azure",

test/e2e/kubernetes/cniWindows1903.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"properties": {
44
"orchestratorProfile": {
55
"orchestratorType": "Kubernetes",
6-
"orchestratorRelease": "1.16",
6+
"orchestratorRelease": "1.17",
77
"kubernetesConfig": {
88
"networkPlugin": "azure",
99
"networkPolicy": "azure",

0 commit comments

Comments
 (0)