Browse Source

Update VaultAppRole documentation to show/use roleRef in its examples (#4035)

Signed-off-by: Mike Tougeron <tougeron@adobe.com>
Co-authored-by: Gustavo Fernandes de Carvalho <17139678+gusfcarvalho@users.noreply.github.com>
Mike Tougeron 1 year ago
parent
commit
9113bced5b

+ 7 - 2
docs/snippets/full-cluster-secret-store.yaml

@@ -68,11 +68,16 @@ spec:
         # AppRole auth: https://www.vaultproject.io/docs/auth/approle
         appRole:
           path: "approle"
-          roleId: "db02de05-fa39-4855-059b-67221c5c2f63"
+          # Instead of referencing the AppRole's ID from the secret, you can also specify it directly
+          # roleId: "db02de05-fa39-4855-059b-67221c5c2f63"
+          roleRef:
+            name: "my-secret"
+            namespace: "secret-admin"
+            key: "vault-role-id"
           secretRef:
             name: "my-secret"
             namespace: "secret-admin"
-            key: "vault-token"
+            key: "vault-role-secret"
 
         # Kubernetes auth: https://www.vaultproject.io/docs/auth/kubernetes
         kubernetes:

+ 6 - 2
docs/snippets/full-secret-store.yaml

@@ -82,10 +82,14 @@ spec:
         # AppRole auth: https://www.vaultproject.io/docs/auth/approle
         appRole:
           path: "approle"
-          roleId: "db02de05-fa39-4855-059b-67221c5c2f63"
+          # Instead of referencing the AppRole's ID from the secret, you can also specify it directly
+          # roleId: "db02de05-fa39-4855-059b-67221c5c2f63"
+          roleRef:
+            name: "my-secret"
+            key: "vault-role-id"
           secretRef:
             name: "my-secret"
-            key: "vault-token"
+            key: "vault-role-secret"
 
         # Kubernetes auth: https://www.vaultproject.io/docs/auth/kubernetes
         kubernetes: