Skip to content

[chore]: prepare v0.141.0 release (#4550) #152

[chore]: prepare v0.141.0 release (#4550)

[chore]: prepare v0.141.0 release (#4550) #152

Workflow file for this run

name: "Create the release"
on:
push:
branches:
- 'release/**'
- 'main'
paths:
- 'versions.txt'
permissions:
contents: read
jobs:
get-versions:
runs-on: ubuntu-latest
outputs:
current_version: ${{ steps.get-versions.outputs.current_version }}
desired_version: ${{ steps.get-versions.outputs.desired_version }}
steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
with:
fetch-depth: 0
- name: "Get versions from versions.txt"
id: get-versions
run: |
echo "desired_version=$(grep -v '#' versions.txt | grep operator= | awk -F= '{print $2}')" >> $GITHUB_OUTPUT
echo "current_version=$(git describe --tags --abbrev=0 | sed 's/^v//')" >> $GITHUB_OUTPUT
release:
permissions:
contents: write # required for creating GitHub releases
runs-on: ubuntu-latest
needs: get-versions
if: needs.get-versions.outputs.desired_version != needs.get-versions.outputs.current_version
env:
CURRENT_VERSION: ${{ needs.get-versions.outputs.current_version }}
DESIRED_VERSION: ${{ needs.get-versions.outputs.desired_version }}
steps:
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
- name: Set up Go
uses: actions/setup-go@4dc6199c7b1a012772edbd06daecab0f50c9053c # v6.1.0
with:
go-version: "~1.25.5"
- name: "generate release resources"
run: make release-artifacts IMG_PREFIX="ghcr.io/open-telemetry/opentelemetry-operator" VERSION=${DESIRED_VERSION}
- name: "create the release in GitHub"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: ./.ci/create-release-github.sh
- name: "refresh go proxy module info on release"
run: |
curl https://proxy.golang.org/github.com/open-telemetry/opentelemetry-operator/@v/${DESIRED_VERSION}.info