Skip to content

Update collector version #247

Update collector version

Update collector version #247

name: Update collector version
on:
workflow_dispatch:
schedule:
- cron: 0 5 * * 1-5
jobs:
update-collector:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: master # this is our target branch
fetch-depth: 0 # we need to fetch all branches
- name: Checkout collector repo
uses: actions/checkout@v4
with:
repository: stackrox/collector
path: deps/collector
fetch-depth: 0 # we need to fetch tags
- name: Update version
run: make -sC deps/collector tag | tee COLLECTOR_VERSION
- name: Create Pull Request
id: cpr
uses: peter-evans/create-pull-request@v6
with:
token: '${{ secrets.RHACS_BOT_GITHUB_TOKEN }}'
commit-message: Update COLLECTOR_VERSION
committer: '${{ secrets.RHACS_BOT_GITHUB_USERNAME }} <${{ secrets.RHACS_BOT_GITHUB_EMAIL }}>'
author: '${{ secrets.RHACS_BOT_GITHUB_USERNAME }} <${{ secrets.RHACS_BOT_GITHUB_EMAIL }}>'
branch: update_collector_version
signoff: false
delete-branch: true
title: 'chore(collector): Update COLLECTOR_VERSION'
body: |
Daily update of COLLECTOR_VERSION to latest master version
labels: |
ci-all-qa-tests
dependencies
team-reviewers: |
collector-team
backend-dep-updaters
draft: false
- name: Enable Pull Request Automerge
if: steps.cpr.outputs.pull-request-operation == 'created'
uses: peter-evans/enable-pull-request-automerge@v3
with:
token: '${{ secrets.RHACS_BOT_GITHUB_TOKEN }}'
pull-request-number: '${{ steps.cpr.outputs.pull-request-number }}'
merge-method: squash