generators.external-secrets.io_gcraccesstokens.yaml 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254
  1. apiVersion: apiextensions.k8s.io/v1
  2. kind: CustomResourceDefinition
  3. metadata:
  4. annotations:
  5. controller-gen.kubebuilder.io/version: v0.19.0
  6. labels:
  7. external-secrets.io/component: controller
  8. name: gcraccesstokens.generators.external-secrets.io
  9. spec:
  10. group: generators.external-secrets.io
  11. names:
  12. categories:
  13. - external-secrets
  14. - external-secrets-generators
  15. kind: GCRAccessToken
  16. listKind: GCRAccessTokenList
  17. plural: gcraccesstokens
  18. singular: gcraccesstoken
  19. scope: Namespaced
  20. versions:
  21. - name: v1alpha1
  22. schema:
  23. openAPIV3Schema:
  24. description: |-
  25. GCRAccessToken generates an GCP access token
  26. that can be used to authenticate with GCR.
  27. properties:
  28. apiVersion:
  29. description: |-
  30. APIVersion defines the versioned schema of this representation of an object.
  31. Servers should convert recognized schemas to the latest internal value, and
  32. may reject unrecognized values.
  33. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
  34. type: string
  35. kind:
  36. description: |-
  37. Kind is a string value representing the REST resource this object represents.
  38. Servers may infer this from the endpoint the client submits requests to.
  39. Cannot be updated.
  40. In CamelCase.
  41. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
  42. type: string
  43. metadata:
  44. type: object
  45. spec:
  46. properties:
  47. auth:
  48. description: Auth defines the means for authenticating with GCP
  49. properties:
  50. secretRef:
  51. properties:
  52. secretAccessKeySecretRef:
  53. description: The SecretAccessKey is used for authentication
  54. properties:
  55. key:
  56. description: |-
  57. A key in the referenced Secret.
  58. Some instances of this field may be defaulted, in others it may be required.
  59. maxLength: 253
  60. minLength: 1
  61. pattern: ^[-._a-zA-Z0-9]+$
  62. type: string
  63. name:
  64. description: The name of the Secret resource being referred
  65. to.
  66. maxLength: 253
  67. minLength: 1
  68. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  69. type: string
  70. namespace:
  71. description: |-
  72. The namespace of the Secret resource being referred to.
  73. Ignored if referent is not cluster-scoped, otherwise defaults to the namespace of the referent.
  74. maxLength: 63
  75. minLength: 1
  76. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
  77. type: string
  78. type: object
  79. type: object
  80. workloadIdentity:
  81. properties:
  82. clusterLocation:
  83. type: string
  84. clusterName:
  85. type: string
  86. clusterProjectID:
  87. type: string
  88. serviceAccountRef:
  89. description: A reference to a ServiceAccount resource.
  90. properties:
  91. audiences:
  92. description: |-
  93. Audience specifies the `aud` claim for the service account token
  94. If the service account uses a well-known annotation for e.g. IRSA or GCP Workload Identity
  95. then this audiences will be appended to the list
  96. items:
  97. type: string
  98. type: array
  99. name:
  100. description: The name of the ServiceAccount resource being
  101. referred to.
  102. maxLength: 253
  103. minLength: 1
  104. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  105. type: string
  106. namespace:
  107. description: |-
  108. Namespace of the resource being referred to.
  109. Ignored if referent is not cluster-scoped, otherwise defaults to the namespace of the referent.
  110. maxLength: 63
  111. minLength: 1
  112. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
  113. type: string
  114. required:
  115. - name
  116. type: object
  117. required:
  118. - clusterLocation
  119. - clusterName
  120. - serviceAccountRef
  121. type: object
  122. workloadIdentityFederation:
  123. description: GCPWorkloadIdentityFederation holds the configurations
  124. required for generating federated access tokens.
  125. properties:
  126. audience:
  127. description: |-
  128. audience is the Secure Token Service (STS) audience which contains the resource name for the workload identity pool and the provider identifier in that pool.
  129. If specified, Audience found in the external account credential config will be overridden with the configured value.
  130. audience must be provided when serviceAccountRef or awsSecurityCredentials is configured.
  131. type: string
  132. awsSecurityCredentials:
  133. description: |-
  134. awsSecurityCredentials is for configuring AWS region and credentials to use for obtaining the access token,
  135. when using the AWS metadata server is not an option.
  136. properties:
  137. awsCredentialsSecretRef:
  138. description: |-
  139. awsCredentialsSecretRef is the reference to the secret which holds the AWS credentials.
  140. Secret should be created with below names for keys
  141. - aws_access_key_id: Access Key ID, which is the unique identifier for the AWS account or the IAM user.
  142. - aws_secret_access_key: Secret Access Key, which is used to authenticate requests made to AWS services.
  143. - aws_session_token: Session Token, is the short-lived token to authenticate requests made to AWS services.
  144. properties:
  145. name:
  146. description: name of the secret.
  147. maxLength: 253
  148. minLength: 1
  149. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  150. type: string
  151. namespace:
  152. description: namespace in which the secret exists.
  153. If empty, secret will looked up in local namespace.
  154. maxLength: 63
  155. minLength: 1
  156. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
  157. type: string
  158. required:
  159. - name
  160. type: object
  161. region:
  162. description: region is for configuring the AWS region
  163. to be used.
  164. example: ap-south-1
  165. maxLength: 50
  166. minLength: 1
  167. pattern: ^[a-z0-9-]+$
  168. type: string
  169. required:
  170. - awsCredentialsSecretRef
  171. - region
  172. type: object
  173. credConfig:
  174. description: |-
  175. credConfig holds the configmap reference containing the GCP external account credential configuration in JSON format and the key name containing the json data.
  176. For using Kubernetes cluster as the identity provider, use serviceAccountRef instead. Operators mounted serviceaccount token cannot be used as the token source, instead
  177. serviceAccountRef must be used by providing operators service account details.
  178. properties:
  179. key:
  180. description: key name holding the external account credential
  181. config.
  182. maxLength: 253
  183. minLength: 1
  184. pattern: ^[-._a-zA-Z0-9]+$
  185. type: string
  186. name:
  187. description: name of the configmap.
  188. maxLength: 253
  189. minLength: 1
  190. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  191. type: string
  192. namespace:
  193. description: namespace in which the configmap exists.
  194. If empty, configmap will looked up in local namespace.
  195. maxLength: 63
  196. minLength: 1
  197. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
  198. type: string
  199. required:
  200. - key
  201. - name
  202. type: object
  203. externalTokenEndpoint:
  204. description: |-
  205. externalTokenEndpoint is the endpoint explicitly set up to provide tokens, which will be matched against the
  206. credential_source.url in the provided credConfig. This field is merely to double-check the external token source
  207. URL is having the expected value.
  208. type: string
  209. serviceAccountRef:
  210. description: |-
  211. serviceAccountRef is the reference to the kubernetes ServiceAccount to be used for obtaining the tokens,
  212. when Kubernetes is configured as provider in workload identity pool.
  213. properties:
  214. audiences:
  215. description: |-
  216. Audience specifies the `aud` claim for the service account token
  217. If the service account uses a well-known annotation for e.g. IRSA or GCP Workload Identity
  218. then this audiences will be appended to the list
  219. items:
  220. type: string
  221. type: array
  222. name:
  223. description: The name of the ServiceAccount resource being
  224. referred to.
  225. maxLength: 253
  226. minLength: 1
  227. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  228. type: string
  229. namespace:
  230. description: |-
  231. Namespace of the resource being referred to.
  232. Ignored if referent is not cluster-scoped, otherwise defaults to the namespace of the referent.
  233. maxLength: 63
  234. minLength: 1
  235. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
  236. type: string
  237. required:
  238. - name
  239. type: object
  240. type: object
  241. type: object
  242. projectID:
  243. description: ProjectID defines which project to use to authenticate
  244. with
  245. type: string
  246. required:
  247. - auth
  248. - projectID
  249. type: object
  250. type: object
  251. served: true
  252. storage: true
  253. subresources:
  254. status: {}