Skip to content

Allow custom version for cloudnative (#4110) (#4119) #9

Allow custom version for cloudnative (#4110) (#4119)

Allow custom version for cloudnative (#4110) (#4119) #9

name: Self update codebase on new release
on:
push:
branches:
- release-*
jobs:
self-update-on-new-release:
name: Self update when new release branch has been created
permissions:
contents: write
pull-requests: write
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
ref: main
- name: Install Python
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
with:
python-version: '3.12'
- name: Install python requirements
run: make prerequisites/python
- name: Find last 3 release branches
run: |
git fetch --prune --tags
git branch -r --list 'origin/release-*' | sort --version-sort | tail -n 3 | tr -d ' ' > release-branches.txt
echo latest branches:
cat release-branches.txt
- name: Update renovate file
run: |
source local/.venv/bin/activate
python3 hack/build/ci/update-renovate-json5.py
- name: Update e2e-tests-ondemand.yaml file
run: |
source local/.venv/bin/activate
python3 hack/build/ci/update-e2e-ondemand-pipeline.py
- name: Create pull request for updating all files
uses: peter-evans/create-pull-request@v7
with:
base: main
delete-branch: true
branch: create-pull-request/update-renovate-json5
branch-suffix: short-commit-hash
add-paths: |
.github/renovate.json5
.github/workflows/e2e-tests-ondemand.yaml
title: '[Automatic] Update because new branch created ${{ github.ref_name }}'
labels: 'ci'
commit-message: self update on new release ${{ github.ref_name }}
committer: GitHub <[email protected]>
author: ${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>
body: |
# Description
This PR updates files after new release has been created:
- `renovate.json5`;
- `e2e-tests-ondemand.yaml` to include last release branch as default.