apiVersion: external-secrets.io/v1
kind: ExternalSecret
metadata:
  name: mas-api-keys
spec:
  refreshInterval: 1h
  secretStoreRef:
    kind: ClusterSecretStore
    name: vault-backend
  target:
    name: mas-api-keys
    creationPolicy: Owner
  data:
  - secretKey: anthropic-api-key
    remoteRef:
      key: mas
      property: ANTHROPIC_API_KEY
---
apiVersion: external-secrets.io/v1
kind: ExternalSecret
metadata:
  name: postgresql-password
spec:
  refreshInterval: 1h
  secretStoreRef:
    kind: ClusterSecretStore
    name: vault-backend
  target:
    name: postgresql-password
    creationPolicy: Owner
  data:
  - secretKey: password
    remoteRef:
      key: postgresql
      property: PASSWORD
