@@ -10,9 +10,6 @@ variables:
1010 RELEASE_VERSION :
1111 value : " "
1212 description : " Version to release (must be in format v1.2.3)"
13- MSI_LATEST_VERSION :
14- value : " "
15- description : " Tmp - Only used by fix-msi-latest job."
1613 GO_VERSION : 1.25.7
1714 WIN_2019_BASE_IMAGE : mcr.microsoft.com/windows/servercore:ltsc2019
1815 WIN_2022_BASE_IMAGE : mcr.microsoft.com/windows/servercore:ltsc2022
@@ -84,60 +81,6 @@ manual_release_trigger:
8481 allow_failure : false
8582 needs : []
8683
87- # Manually triggered job to fix msi/release/latest.txt on S3 - tmp
88- fix-msi-latest :
89- stage : manual-release
90- image : ' ${DOCKER_CICD_REPO}/ci-container/python-3.12-bookworm:3.5.0'
91- id_tokens :
92- CI_JOB_JWT :
93- aud : $CICD_VAULT_ADDR
94- rules :
95- - if : ' $CI_PIPELINE_SOURCE == "web" && $MSI_LATEST_VERSION && $CI_COMMIT_BRANCH == "main"'
96- when : on_success
97- needs : []
98- script :
99- - |
100- set -euo pipefail
101- VERSION="$MSI_LATEST_VERSION"
102-
103- if ! echo "$VERSION" | grep -Eq '^[0-9]+\.[0-9]+\.[0-9]+$'; then
104- echo "MSI_LATEST_VERSION must be in format X.Y.Z (e.g. 0.145.0), got: '$VERSION'" >&2
105- exit 1
106- fi
107- if echo "$VERSION" | grep -Eq '^0\.0\.'; then
108- echo "MSI_LATEST_VERSION cannot be a placeholder version (0.0.x)" >&2
109- exit 1
110- fi
111-
112- MSI_URL="https://dl.signalfx.com/splunk-otel-collector/msi/release/splunk-otel-collector-${VERSION}-amd64.msi"
113- # Use a ranged GET (1 byte) with redirect-following to handle CDN/S3 redirects
114- if ! curl -fsSL --range 0-0 "$MSI_URL" -o /dev/null; then
115- echo "MSI not found or not accessible at $MSI_URL. Verify the version exists before updating latest.txt." >&2
116- exit 1
117- fi
118- echo "Verified MSI exists at $MSI_URL"
119- - pip3 install awscli
120- - |
121- creds-helper init
122- eval $(creds-helper aws --eval "aws:v1/o11y-infra/role/o11y_gdi_otel_releaser_role")
123- - |
124- set -euo pipefail
125- VERSION="$MSI_LATEST_VERSION"
126- echo "$VERSION" > /tmp/latest.txt
127- echo "Updating s3://public-downloads--signalfuse-com/splunk-otel-collector/msi/release/latest.txt to '$VERSION' ..."
128- aws s3 cp /tmp/latest.txt s3://public-downloads--signalfuse-com/splunk-otel-collector/msi/release/latest.txt
129- echo "Invalidating CloudFront cache ..."
130- aws cloudfront create-invalidation --distribution-id EJH671JAOI5SN --paths "/splunk-otel-collector/msi/release/latest.txt"
131-
132- echo "Waiting for CloudFront invalidation to propagate ..."
133- sleep 60
134- ACTUAL=$(curl -sf https://dl.signalfx.com/splunk-otel-collector/msi/release/latest.txt | tr -d '[:space:]')
135- if [ "$ACTUAL" = "$VERSION" ]; then
136- echo "Verified: latest.txt is now '$ACTUAL'"
137- else
138- echo "WARNING: latest.txt is '$ACTUAL', expected '$VERSION'. CloudFront may still be propagating." >&2
139- fi
140-
14184fossa :
14285 extends : .oss-scan
14386 stage : sast-oss-scan
@@ -200,9 +143,6 @@ fossa:
200143
201144.trigger-filter :
202145 rules :
203- # Skip all build/release jobs when only fix-msi-latest is intended
204- - if : ' $MSI_LATEST_VERSION && $RELEASE_VERSION == ""'
205- when : never
206146 - &main-condition
207147 if : $CI_COMMIT_BRANCH == "main"
208148 # commenting out the original commit-tag trigger condition for collector release
@@ -292,8 +232,6 @@ fossa:
292232
293233.xray-scan-package :
294234 rules :
295- - if : ' $MSI_LATEST_VERSION && $RELEASE_VERSION == ""'
296- when : never
297235 - if : $CI_PIPELINE_SOURCE == "schedule"
298236 when : never
299237 - if : $CI_COMMIT_BRANCH == "main"
@@ -1912,10 +1850,7 @@ xray-scan-docker:
19121850 only :
19131851 - main
19141852 except :
1915- refs :
1916- - schedules
1917- variables :
1918- - $MSI_LATEST_VERSION
1853+ - schedules
19191854 extends : .container-scan
19201855 stage : xray-scan
19211856 parallel :
0 commit comments