@@ -168,14 +168,15 @@ Paste the following task towards the end of your release step in the release
168
168
pipeline in the Azure DevOps portal :
169
169
170
170
` ` ` yaml
171
- latest_commit=$(git rev-parse --short HEAD) VERSION_TO_DOWNLOAD=$(curl -s
172
- "https://api.github.com/repos/CatalystCode/spk/releases/latest" | grep
173
- "tag_name" | sed -E 's/.*"([^"]+)".*/\1 /') echo "Downloading SPK" curl
174
- https://raw.githubusercontent.com/Microsoft/bedrock/master/gitops/azure-devops/build.sh
175
- > build.sh chmod +x build.sh . ./build.sh --source-only get_spk_version
176
- download_spk ./spk/spk deployment create -n $(ACCOUNT_NAME) -k $(ACCOUNT_KEY)
177
- -t $(TABLE_NAME) -p $(PARTITION_KEY) --p2 $(Release.ReleaseId) --hld-commit-id
178
- $latest_commit --env $(Release.EnvironmentName) --image-tag $(Build.BuildId)
171
+ latest_commit=$(git rev-parse --short HEAD)
172
+ VERSION_TO_DOWNLOAD=$(curl -s "https://api.github.com/repos/CatalystCode/spk/releases/latest" | grep "tag_name" | sed -E 's/.*"([^"]+)".*/\1 /')
173
+ echo "Downloading SPK"
174
+ curl https://raw.githubusercontent.com/Microsoft/bedrock/master/gitops/azure-devops/build.sh > build.sh
175
+ chmod +x build.sh
176
+ . ./build.sh --source-only
177
+ get_spk_version
178
+ download_spk
179
+ ./spk/spk deployment create -n $(ACCOUNT_NAME) -k $(ACCOUNT_KEY) -t $(TABLE_NAME) -p $(PARTITION_KEY) --p2 $(Release.ReleaseId) --hld-commit-id $latest_commit --env $(Release.EnvironmentName) --image-tag $(Build.BuildId)
179
180
` ` `
180
181
181
182
This task is similar to the one from step 1 but instead passes the information
@@ -190,15 +191,15 @@ Paste the following yaml task towards the end of your image tag release stage in
190
191
your multi-stage `azure-pipelines.yml` :
191
192
192
193
` ` ` yaml
193
- latest_commit=$(git rev-parse --short HEAD) tag_name=$(Build.BuildId)
194
- VERSION_TO_DOWNLOAD =$(curl -s
195
- "https://api.github.com/repos/CatalystCode/spk/releases/latest" | grep
196
- "tag_name" | sed -E 's/.*"([^"]+)".*/ \1 /') echo "Downloading SPK" curl
197
- https://raw.githubusercontent.com/Microsoft/bedrock/master/gitops/azure-devops/ build.sh
198
- > build.sh chmod +x build.sh . . /build.sh --source-only get_spk_version
199
- download_spk ./spk/spk deployment create -n $(ACCOUNT_NAME) -k $(ACCOUNT_KEY)
200
- -t $(TABLE_NAME) -p $(PARTITION_KEY) --p2 $(Build.BuildId) --hld-commit-id
201
- $latest_commit --env $(Build.SourceBranchName) --image-tag $tag_name
194
+ latest_commit=$(git rev-parse --short HEAD)
195
+ tag_name =$(Build.BuildId)
196
+ echo "Downloading SPK"
197
+ curl https://raw.githubusercontent.com/Microsoft/bedrock/master/gitops/azure-devops/build.sh > build.sh
198
+ chmod +x build.sh
199
+ . . /build.sh --source-only
200
+ get_spk_version
201
+ download_spk
202
+ ./spk/spk deployment create -n $(ACCOUNT_NAME) -k $(ACCOUNT_KEY) -t $(TABLE_NAME) -p $(PARTITION_KEY) --p2 $(Build.BuildId) --hld-commit-id $latest_commit --env $(Build.SourceBranchName) --image-tag $tag_name
202
203
` ` `
203
204
204
205
Make sure your variable `tag_name` in this script matches the `tag_name` in the
0 commit comments