From 9722a81a29d0c4d51fc85ee3b33bc71a19611783 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 8 Jul 2026 19:17:44 +0000 Subject: [PATCH 1/3] refactor: move nginx cluster manifests --- README.md | 2 ++ .../git-repository.yaml | 0 .../kustomization-nginx-application.yaml | 0 kustomize-nginx-cluster/kustomization.yaml | 5 ++++ kustomize-nginx-cluster/namespace.yaml | 4 +++ kustomize-nginx-cluster/rbac.yaml | 26 +++++++++++++++++++ 6 files changed, 37 insertions(+) rename {applications/kustomize-nginx-cluster => kustomize-nginx-cluster}/git-repository.yaml (100%) rename {applications/kustomize-nginx-cluster => kustomize-nginx-cluster}/kustomization-nginx-application.yaml (100%) create mode 100644 kustomize-nginx-cluster/kustomization.yaml create mode 100644 kustomize-nginx-cluster/namespace.yaml create mode 100644 kustomize-nginx-cluster/rbac.yaml diff --git a/README.md b/README.md index 80f2321..b0b2224 100644 --- a/README.md +++ b/README.md @@ -17,6 +17,7 @@ fleet-gitops/ ├── applications/ # Application resources synced to the hub cluster │ ├── kustomize-nginx/ # NGINX app using Flux CD + Kustomize │ └── simple-guestbook/ # Guestbook app using Argo CD +├── kustomize-nginx-cluster/ # Flux manifests applied on member clusters for NGINX ├── rollout/ # Hub-level bootstrap manifests │ ├── kustomize-nginx/ # Flux GitRepository & Kustomization for NGINX │ └── guestbook/ # Argo CD AppProject & Application for Guestbook @@ -39,6 +40,7 @@ Deploys an NGINX application across multiple clusters using Flux CD for GitOps r - **Hub bootstrap:** [`rollout/kustomize-nginx/`](rollout/kustomize-nginx/) - **Application resources:** [`applications/kustomize-nginx/`](applications/kustomize-nginx/) +- **Member-cluster Flux resources:** [`kustomize-nginx-cluster/`](kustomize-nginx-cluster/) - **Detailed guide:** [`rollout/kustomize-nginx/README.md`](rollout/kustomize-nginx/README.md) ### Guestbook via Argo CD diff --git a/applications/kustomize-nginx-cluster/git-repository.yaml b/kustomize-nginx-cluster/git-repository.yaml similarity index 100% rename from applications/kustomize-nginx-cluster/git-repository.yaml rename to kustomize-nginx-cluster/git-repository.yaml diff --git a/applications/kustomize-nginx-cluster/kustomization-nginx-application.yaml b/kustomize-nginx-cluster/kustomization-nginx-application.yaml similarity index 100% rename from applications/kustomize-nginx-cluster/kustomization-nginx-application.yaml rename to kustomize-nginx-cluster/kustomization-nginx-application.yaml diff --git a/kustomize-nginx-cluster/kustomization.yaml b/kustomize-nginx-cluster/kustomization.yaml new file mode 100644 index 0000000..e6ad8b7 --- /dev/null +++ b/kustomize-nginx-cluster/kustomization.yaml @@ -0,0 +1,5 @@ +resources: + - namespace.yaml + - rbac.yaml + - git-repository.yaml + - kustomization-nginx-application.yaml diff --git a/kustomize-nginx-cluster/namespace.yaml b/kustomize-nginx-cluster/namespace.yaml new file mode 100644 index 0000000..88839f0 --- /dev/null +++ b/kustomize-nginx-cluster/namespace.yaml @@ -0,0 +1,4 @@ +apiVersion: v1 +kind: Namespace +metadata: + name: nginx-demo diff --git a/kustomize-nginx-cluster/rbac.yaml b/kustomize-nginx-cluster/rbac.yaml new file mode 100644 index 0000000..091b2e5 --- /dev/null +++ b/kustomize-nginx-cluster/rbac.yaml @@ -0,0 +1,26 @@ +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: flux-permissions + namespace: nginx-demo +rules: +- apiGroups: ["apps"] + resources: ["deployments", "replicasets"] + verbs: ["get", "list", "watch", "create", "update", "patch", "delete"] +- apiGroups: [""] + resources: ["pods", "configmaps", "secrets", "services", "serviceaccounts"] + verbs: ["get", "list", "watch", "create", "update", "patch", "delete"] +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: flux-permissions + namespace: nginx-demo +subjects: +- kind: ServiceAccount + name: flux-applier + namespace: flux-system +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: flux-permissions From b486023f0eb756095eaa35bbadde11ce997f12cf Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 8 Jul 2026 19:18:41 +0000 Subject: [PATCH 2/3] fix: include nginx cluster service account --- kustomize-nginx-cluster/kustomization.yaml | 1 + kustomize-nginx-cluster/serviceaccount.yaml | 5 +++++ 2 files changed, 6 insertions(+) create mode 100644 kustomize-nginx-cluster/serviceaccount.yaml diff --git a/kustomize-nginx-cluster/kustomization.yaml b/kustomize-nginx-cluster/kustomization.yaml index e6ad8b7..86a8100 100644 --- a/kustomize-nginx-cluster/kustomization.yaml +++ b/kustomize-nginx-cluster/kustomization.yaml @@ -1,5 +1,6 @@ resources: - namespace.yaml + - serviceaccount.yaml - rbac.yaml - git-repository.yaml - kustomization-nginx-application.yaml diff --git a/kustomize-nginx-cluster/serviceaccount.yaml b/kustomize-nginx-cluster/serviceaccount.yaml new file mode 100644 index 0000000..3ff0f67 --- /dev/null +++ b/kustomize-nginx-cluster/serviceaccount.yaml @@ -0,0 +1,5 @@ +apiVersion: v1 +kind: ServiceAccount +metadata: + name: flux-applier + namespace: flux-system From 3ba9038e1c3e5e030ca0e53d6d64bb8a7e99a341 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 8 Jul 2026 19:33:53 +0000 Subject: [PATCH 3/3] chore: remove service account from kustomize-nginx-cluster --- kustomize-nginx-cluster/kustomization.yaml | 1 - kustomize-nginx-cluster/serviceaccount.yaml | 5 ----- 2 files changed, 6 deletions(-) delete mode 100644 kustomize-nginx-cluster/serviceaccount.yaml diff --git a/kustomize-nginx-cluster/kustomization.yaml b/kustomize-nginx-cluster/kustomization.yaml index 86a8100..e6ad8b7 100644 --- a/kustomize-nginx-cluster/kustomization.yaml +++ b/kustomize-nginx-cluster/kustomization.yaml @@ -1,6 +1,5 @@ resources: - namespace.yaml - - serviceaccount.yaml - rbac.yaml - git-repository.yaml - kustomization-nginx-application.yaml diff --git a/kustomize-nginx-cluster/serviceaccount.yaml b/kustomize-nginx-cluster/serviceaccount.yaml deleted file mode 100644 index 3ff0f67..0000000 --- a/kustomize-nginx-cluster/serviceaccount.yaml +++ /dev/null @@ -1,5 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: flux-applier - namespace: flux-system