k3s/.github/workflows/updatecli.yaml
dependabot[bot] da19e1ac48
build(deps): bump updatecli/updatecli-action from 2.100.0 to 3.0.0
Bumps [updatecli/updatecli-action](https://github.com/updatecli/updatecli-action) from 2.100.0 to 3.0.0.
- [Release notes](https://github.com/updatecli/updatecli-action/releases)
- [Commits](4b17f4ea78...2cc8e6d8e3)

---
updated-dependencies:
- dependency-name: updatecli/updatecli-action
  dependency-version: 3.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-03-30 10:24:54 +00:00

44 lines
1.7 KiB
YAML

name: "Updatecli: Dependency Management"
on:
schedule:
# Runs at 06 PM UTC
- cron: '0 18 * * 0'
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
permissions:
contents: read
jobs:
updatecli:
runs-on: ubuntu-latest
permissions:
contents: write
issues: write
pull-requests: write
if: github.ref == 'refs/heads/main'
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
- name: Install Go
uses: ./.github/actions/setup-go
- name: Delete leftover UpdateCLI branches
run: |
gh pr list --search "is:closed is:pr head:updatecli_" --json headRefName --jq ".[].headRefName" | sort -u > closed_prs_branches.txt
gh pr list --search "is:open is:pr head:updatecli_" --json headRefName --jq ".[].headRefName" | sort -u > open_prs_branches.txt
for branch in $(comm -23 closed_prs_branches.txt open_prs_branches.txt); do if (git ls-remote --exit-code --heads origin "$branch"); then echo "Deleting leftover UpdateCLI branch - $branch"; git push origin --delete "$branch"; fi done
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Install Updatecli
uses: updatecli/updatecli-action@2cc8e6d8e356d76b0280cdd03766c36596a0614e # v3.0.0
- name: Apply Updatecli
# Never use '--debug' option, because it might leak the access tokens.
run: "updatecli apply --clean --config ./updatecli/updatecli.d/ --values ./updatecli/values.yaml"
env:
UPDATECLI_GITHUB_ACTOR: ${{ github.actor }}
UPDATECLI_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}