# services/vaultwarden/ariadne-rbac.yaml
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
  name: ariadne-vaultwarden-admin-reader
  namespace: vaultwarden
rules:
  - apiGroups: [""]
    resources: ["secrets"]
    verbs: ["get"]
    resourceNames: ["vaultwarden-admin"]
  - apiGroups: [""]
    resources: ["pods"]
    verbs: ["get", "list"]
---
apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
  name: ariadne-vaultwarden-admin-reader
  namespace: vaultwarden
roleRef:
  apiGroup: rbac.authorization.k8s.io
  kind: Role
  name: ariadne-vaultwarden-admin-reader
subjects:
  - kind: ServiceAccount
    name: ariadne
    namespace: maintenance
