chore(deps): update dependency fluxcd/flux2 to v2 #79
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# verify with local kind k8s cluster. | |
name: Flux2 E2E test | |
on: | |
workflow_dispatch: | |
pull_request: | |
branches: [main] | |
paths: | |
- "flux2/**" | |
- ".github/workflows/flux2*" | |
jobs: | |
kubernetes: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: true | |
matrix: | |
cluster: [staging, prod] | |
solution: [multi-clusters, multi-tenants] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Setup tools | |
uses: ./.github/actions/flux2/tools | |
- name: Setup Flux | |
uses: fluxcd/flux2/action@main | |
- name: Setup Kubernetes | |
uses: engineerd/[email protected] | |
with: | |
# renovate: datasource=go depName=sigs.k8s.io/kind | |
version: v0.12.0 | |
- name: Install Flux in Kubernetes Kind | |
run: | | |
flux check --pre | |
flux install | |
- name: Setup cluster reconciliation | |
run: | | |
kubectl apply -f - <<EOF > cat | |
apiVersion: source.toolkit.fluxcd.io/v1beta2 | |
kind: GitRepository | |
metadata: | |
name: flux-system | |
namespace: flux-system | |
spec: | |
interval: 15m | |
ref: | |
branch: ${GITHUB_HEAD_REF} | |
url: ${{ github.event.repository.html_url }} | |
ignore: /flux2/${{ matrix.solution }}/clusters/${{ matrix.cluster }}/flux-system/ | |
EOF | |
flux create kustomization flux-system \ | |
--source=flux-system \ | |
--path=./flux2/${{ matrix.solution }}/clusters/${{ matrix.cluster }} | |
- name: Verify cluster reconciliations | |
timeout-minutes: 5 | |
run: | | |
while flux get all --all-namespaces --status-selector=ready=false | grep False | |
do | |
sleep 5 | |
done | |
- name: Debug failure | |
if: failure() | |
run: | | |
kubectl -n flux-system get all | |
kubectl -n flux-system logs deploy/source-controller | |
kubectl -n flux-system logs deploy/kustomize-controller | |
kubectl -n flux-system logs deploy/helm-controller | |
flux get all --all-namespaces |