Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(weave-gitops): switch to OIDC only auth #1737

Merged
merged 1 commit into from
Dec 22, 2024

Conversation

martinohmann
Copy link
Owner

No description provided.

@github-actions github-actions bot added area/kubernetes Changes made in the kubernetes directory cluster/main cluster/storage labels Dec 22, 2024
Copy link

kustomization changes in kubernetes/storage

--- kubernetes/storage/apps/flux-system/weave-gitops/app Kustomization: flux-system/weave-gitops HelmRelease: flux-system/weave-gitops

+++ kubernetes/storage/apps/flux-system/weave-gitops/app Kustomization: flux-system/weave-gitops HelmRelease: flux-system/weave-gitops

@@ -26,12 +26,15 @@

     keepHistory: false
   upgrade:
     cleanupOnFail: true
     remediation:
       retries: 3
   values:
+    additionalArgs:
+    - --auth-methods=oidc
+    - --oidc-secret-name=weave-gitops-oidc-auth
     adminUser:
       create: true
       createSecret: false
       username: admin
     ingress:
       className: internal
@@ -46,15 +49,17 @@

         - gitops.storage.18b.haus
     metrics:
       enabled: true
     networkPolicy:
       create: false
     podAnnotations:
-      secret.reloader.stakater.com/reload: cluster-user-auth,oidc-auth
+      secret.reloader.stakater.com/reload: weave-gitops-oidc-auth
     rbac:
       create: true
+      viewSecretsResourceNames:
+      - weave-gitops-oidc-auth
     resources:
       limits:
         memory: 140Mi
       requests:
         cpu: 30m
         memory: 70Mi

Copy link

helmrelease changes in kubernetes/storage

--- HelmRelease: flux-system/weave-gitops ClusterRole: flux-system/weave-gitops

+++ HelmRelease: flux-system/weave-gitops ClusterRole: flux-system/weave-gitops

@@ -16,14 +16,13 @@

   resources:
   - secrets
   verbs:
   - get
   - list
   resourceNames:
-  - cluster-user-auth
-  - oidc-auth
+  - weave-gitops-oidc-auth
 - apiGroups:
   - ''
   resources:
   - namespaces
   verbs:
   - get
--- HelmRelease: flux-system/weave-gitops Deployment: flux-system/weave-gitops

+++ HelmRelease: flux-system/weave-gitops Deployment: flux-system/weave-gitops

@@ -15,13 +15,13 @@

     matchLabels:
       app.kubernetes.io/name: weave-gitops
       app.kubernetes.io/instance: weave-gitops
   template:
     metadata:
       annotations:
-        secret.reloader.stakater.com/reload: cluster-user-auth,oidc-auth
+        secret.reloader.stakater.com/reload: weave-gitops-oidc-auth
       labels:
         app.kubernetes.io/name: weave-gitops
         app.kubernetes.io/instance: weave-gitops
         app.kubernetes.io/part-of: weave-gitops
         weave.works/app: weave-gitops-oss
     spec:
@@ -43,12 +43,14 @@

         args:
         - --log-level
         - info
         - --insecure
         - --enable-metrics
         - --metrics-address=:2112
+        - --auth-methods=oidc
+        - --oidc-secret-name=weave-gitops-oidc-auth
         ports:
         - name: http
           containerPort: 9001
           protocol: TCP
         - name: http-metrics
           containerPort: 2112

Copy link

helmrelease changes in kubernetes/main

--- HelmRelease: flux-system/weave-gitops ClusterRole: flux-system/weave-gitops

+++ HelmRelease: flux-system/weave-gitops ClusterRole: flux-system/weave-gitops

@@ -16,14 +16,13 @@

   resources:
   - secrets
   verbs:
   - get
   - list
   resourceNames:
-  - cluster-user-auth
-  - oidc-auth
+  - weave-gitops-oidc-auth
 - apiGroups:
   - ''
   resources:
   - namespaces
   verbs:
   - get
--- HelmRelease: flux-system/weave-gitops Deployment: flux-system/weave-gitops

+++ HelmRelease: flux-system/weave-gitops Deployment: flux-system/weave-gitops

@@ -15,13 +15,13 @@

     matchLabels:
       app.kubernetes.io/name: weave-gitops
       app.kubernetes.io/instance: weave-gitops
   template:
     metadata:
       annotations:
-        secret.reloader.stakater.com/reload: cluster-user-auth,oidc-auth
+        secret.reloader.stakater.com/reload: weave-gitops-oidc-auth
       labels:
         app.kubernetes.io/name: weave-gitops
         app.kubernetes.io/instance: weave-gitops
         app.kubernetes.io/part-of: weave-gitops
         weave.works/app: weave-gitops-oss
     spec:
@@ -43,12 +43,14 @@

         args:
         - --log-level
         - info
         - --insecure
         - --enable-metrics
         - --metrics-address=:2112
+        - --auth-methods=oidc
+        - --oidc-secret-name=weave-gitops-oidc-auth
         ports:
         - name: http
           containerPort: 9001
           protocol: TCP
         - name: http-metrics
           containerPort: 2112

Copy link

kustomization changes in kubernetes/main

--- kubernetes/main/apps/flux-system/weave-gitops/app Kustomization: flux-system/weave-gitops HelmRelease: flux-system/weave-gitops

+++ kubernetes/main/apps/flux-system/weave-gitops/app Kustomization: flux-system/weave-gitops HelmRelease: flux-system/weave-gitops

@@ -26,12 +26,15 @@

     keepHistory: false
   upgrade:
     cleanupOnFail: true
     remediation:
       retries: 3
   values:
+    additionalArgs:
+    - --auth-methods=oidc
+    - --oidc-secret-name=weave-gitops-oidc-auth
     adminUser:
       create: true
       createSecret: false
       username: admin
     ingress:
       className: internal
@@ -46,15 +49,17 @@

         - gitops.18b.haus
     metrics:
       enabled: true
     networkPolicy:
       create: false
     podAnnotations:
-      secret.reloader.stakater.com/reload: cluster-user-auth,oidc-auth
+      secret.reloader.stakater.com/reload: weave-gitops-oidc-auth
     rbac:
       create: true
+      viewSecretsResourceNames:
+      - weave-gitops-oidc-auth
     resources:
       limits:
         memory: 140Mi
       requests:
         cpu: 30m
         memory: 70Mi

@martinohmann martinohmann merged commit 91584d5 into main Dec 22, 2024
10 checks passed
@martinohmann martinohmann deleted the weave-gitops/oidc-auth-only branch December 22, 2024 12:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/kubernetes Changes made in the kubernetes directory cluster/main cluster/storage
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant