Skip to content

Commit

Permalink
feat: make job into multi-cluster
Browse files Browse the repository at this point in the history
  • Loading branch information
joryirving committed Dec 29, 2024
1 parent bdeccc6 commit ca5e3b6
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 12 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/pre-pull-images.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ jobs:
fail-fast: false
outputs:
images: ${{ steps.extract-images.outputs.images }}
paths: ${{ fromJSON(needs.changed-clusters.outputs.matrix) }}
paths: ${{ needs.changed-clusters.outputs.matrix }}
steps:
- name: Configure 1password
uses: 1password/load-secrets-action/configure@v2
Expand Down Expand Up @@ -192,7 +192,9 @@ jobs:
"aqua:siderolabs/talos" = "latest"
- name: Pre-pull Image
run: talosctl -n $NODE_IP image pull ${{ matrix.images }}
run: |
NODE=$(talosctl config info --output json | jq --raw-output '.nodes[]' | shuf -n 1)
talosctl -n $NODE image pull ${{ matrix.images }}
# Summarize matrix https://git.luolix.topmunity/t/status-check-for-a-matrix-jobs/127354/7
pre-pull-images-success:
Expand Down
11 changes: 2 additions & 9 deletions .github/workflows/schemas.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
env:
BOT_APP_ID: op://Kubernetes/github-bot/BOT_APP_ID
BOT_APP_PRIVATE_KEY: op://Kubernetes/github-bot/BOT_APP_PRIVATE_KEY
KUBECONFIG: op://Kubernetes/kubernetes/KUBECONFIG_BASE64
KUBECONFIG: op://Kubernetes/kubernetes/KUBECONFIG
CLOUDFLARE_API_TOKEN: op://Kubernetes/cloudflare/CLOUDFLARE_API_TOKEN_GHA
CLOUDFLARE_ACCOUNT_ID: op://Kubernetes/cloudflare/CLOUDFLARE_ACCOUNT_TAG

Expand Down Expand Up @@ -61,14 +61,7 @@ jobs:
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 18.x

- name: Write kubeconfig
id: kubeconfig
uses: timheuer/base64-to-file@v1
with:
encodedString: ${{ env.KUBECONFIG }}
fileName: kubeconfig
node-version: 20.x

- name: Download and run crd-extractor
env:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ spec:
runnerScaleSetName: gha-runner-scale-set
githubConfigUrl: https://github.com/joryirving/home-ops
minRunners: 1
maxRunners: 10
maxRunners: 6
containerMode:
type: dind
template:
Expand Down

0 comments on commit ca5e3b6

Please sign in to comment.