Skip to content

update-flux

update-flux #22375

Workflow file for this run

name: update-flux
on:
workflow_dispatch:
schedule:
- cron: "0 * * * *"
permissions:
contents: write
pull-requests: write
jobs:
components:
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v4
- name: Setup Flux CLI
uses: fluxcd/flux2/action@main
with:
version: 'latest'
- name: Check for updates
id: update
run: |
# flux install \
# --export > ./clusters/production/flux-system/gotk-components.yaml
# flux install \
# --export > ./clusters/staging/flux-system/gotk-components.yaml
# flux install --components-extra=image-reflector-controller,image-automation-controller \
# --export > ./clusters/aks-kuberkingdon/flux-system/gotk-components.yaml
# flux install --components-extra=image-reflector-controller,image-automation-controller \
# --export > ./clusters/gke-geekingdon/flux-system/gotk-components.yaml
flux install --components-extra=image-reflector-controller,image-automation-controller \
--export > ./clusters/moo-cluster/flux-system/gotk-components.yaml
flux install --components-extra=image-reflector-controller,image-automation-controller \
--export > ./clusters/hephy-staging/flux-system/gotk-components.yaml
flux install --components-extra=image-reflector-controller,image-automation-controller \
--export > ./clusters/howard-moomboo-space/flux-system/gotk-components.yaml
VERSION="$(flux -v)"
echo "flux_version=$VERSION" >> $GITHUB_OUTPUT
- name: Create Pull Request
uses: peter-evans/create-pull-request@v6
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: update-flux
commit-message: Update to ${{ steps.update.outputs.flux_version }}
title: Update to ${{ steps.update.outputs.flux_version }}
body: |
${{ steps.update.outputs.flux_version }}