full-secret-store.yaml 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141
  1. apiVersion: external-secrets.io/v1beta1
  2. kind: SecretStore
  3. metadata:
  4. name: example
  5. namespace: example-ns
  6. spec:
  7. # Used to select the correct ESO controller (think: ingress.ingressClassName)
  8. # The ESO controller is instantiated with a specific controller name
  9. # and filters ES based on this property
  10. # Optional
  11. controller: dev
  12. # You can specify retry settings for the http connection
  13. # these fields allow you to set a maxRetries before failure, and
  14. # an interval between the retries.
  15. # Current supported providers: AWS, Hashicorp Vault, IBM
  16. retrySettings:
  17. maxRetries: 5
  18. retryInterval: "10s"
  19. # provider field contains the configuration to access the provider
  20. # which contains the secret exactly one provider must be configured.
  21. provider:
  22. # (1): AWS Secrets Manager
  23. # aws configures this store to sync secrets using AWS Secret Manager provider
  24. aws:
  25. service: SecretsManager
  26. # Role is a Role ARN which the SecretManager provider will assume
  27. role: iam-role
  28. # AWS Region to be used for the provider
  29. region: eu-central-1
  30. # Auth defines the information necessary to authenticate against AWS by
  31. # getting the accessKeyID and secretAccessKey from an already created Kubernetes Secret
  32. auth:
  33. secretRef:
  34. accessKeyIDSecretRef:
  35. name: awssm-secret
  36. key: access-key
  37. secretAccessKeySecretRef:
  38. name: awssm-secret
  39. key: secret-access-key
  40. # (2) Hashicorp Vault
  41. vault:
  42. server: "https://vault.acme.org"
  43. # Path is the mount path of the Vault KV backend endpoint
  44. # Used as a path prefix for the external secret key
  45. path: "secret"
  46. # Version is the Vault KV secret engine version.
  47. # This can be either "v1" or "v2", defaults to "v2"
  48. version: "v2"
  49. # vault enterprise namespace: https://www.vaultproject.io/docs/enterprise/namespaces
  50. namespace: "a-team"
  51. # base64 encoded string of certificate
  52. caBundle: "..."
  53. # Instead of caBundle you can also specify a caProvider
  54. # this will retrieve the cert from a Secret or ConfigMap
  55. caProvider:
  56. # Can be Secret or ConfigMap
  57. type: "Secret"
  58. name: "my-cert-secret"
  59. key: "cert-key"
  60. # client side related TLS communication, when the Vault server requires mutual authentication
  61. tls:
  62. certSecretRef:
  63. namespace: ...
  64. name: "my-cert-secret"
  65. key: "tls.crt"
  66. keySecretRef:
  67. namespace: ...
  68. name: "my-cert-secret"
  69. key: "tls.key"
  70. auth:
  71. # static token: https://www.vaultproject.io/docs/auth/token
  72. tokenSecretRef:
  73. name: "my-secret"
  74. key: "vault-token"
  75. # AppRole auth: https://www.vaultproject.io/docs/auth/approle
  76. appRole:
  77. path: "approle"
  78. # Instead of referencing the AppRole's ID from the secret, you can also specify it directly
  79. # roleId: "db02de05-fa39-4855-059b-67221c5c2f63"
  80. roleRef:
  81. name: "my-secret"
  82. key: "vault-role-id"
  83. secretRef:
  84. name: "my-secret"
  85. key: "vault-role-secret"
  86. # Kubernetes auth: https://www.vaultproject.io/docs/auth/kubernetes
  87. kubernetes:
  88. mountPath: "kubernetes"
  89. role: "demo"
  90. # Optional service account reference
  91. serviceAccountRef:
  92. name: "my-sa"
  93. # Optional secret field containing a Kubernetes ServiceAccount JWT
  94. # used for authenticating with Vault
  95. secretRef:
  96. name: "my-secret"
  97. key: "vault"
  98. # TLS certificates auth method: https://developer.hashicorp.com/vault/docs/auth/cert
  99. cert:
  100. clientCert:
  101. namespace: ...
  102. name: "my-cert-secret"
  103. key: "tls.crt"
  104. secretRef:
  105. namespace: ...
  106. name: "my-cert-secret"
  107. key: "tls.key"
  108. # (3): GCP Secret Manager
  109. gcpsm:
  110. # Auth defines the information necessary to authenticate against GCP by getting
  111. # the credentials from an already created Kubernetes Secret.
  112. auth:
  113. secretRef:
  114. secretAccessKeySecretRef:
  115. name: gcpsm-secret
  116. key: secret-access-credentials
  117. projectID: myproject
  118. # (TODO): add more provider examples here
  119. status:
  120. # Standard condition schema
  121. conditions:
  122. # SecretStore ready condition indicates the given store is in ready
  123. # state and able to referenced by ExternalSecrets
  124. # If the `status` of this condition is `False`, ExternalSecret controllers
  125. # should prevent attempts to fetch secrets
  126. - type: Ready
  127. status: "False"
  128. reason: "ConfigError"
  129. message: "SecretStore validation failed"
  130. lastTransitionTime: "2019-08-12T12:33:02Z"