Skip to content

updatecli

updatecli #41898

Workflow file for this run

name: updatecli
on:
release:
workflow_dispatch:
push:
branches: [main]
pull_request:
branches: [main]
schedule:
# Run every hour
- cron: "0 * * * *"
permissions: {}
jobs:
updatecli:
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: "Checkout"
uses: "actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683" # v4.2.2
- name: "Setup updatecli"
uses: "updatecli/updatecli-action@a0473702445985223bf6e3229101678baecc5dca" # v2
- name: Set up Go
uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5.5.0
with:
go-version-file: "go.mod"
id: go
- name: "Run updatecli in dryrun"
run: "updatecli compose diff"
env:
GITHUB_ACTOR: ${{ github.actor }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- uses: actions/create-github-app-token@df432ceedc7162793a195dd1713ff69aefc7379e # v2.0.6
id: generate_token
if: github.ref == 'refs/heads/main'
with:
app-id: ${{ secrets.UPDATECLIBOT_APP_ID }}
private-key: ${{ secrets.UPDATECLIBOT_APP_PRIVKEY }}
- name: "Run updatecli"
if: github.ref == 'refs/heads/main'
run: "updatecli compose apply"
env:
GITHUB_ACTOR: ${{ secrets.UPDATECLI_BOT_GITHUB_ACTOR }}
GITHUB_TOKEN: ${{ steps.generate_token.outputs.token }}