external-secrets.io_externalsecrets.yaml 67 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434
  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: externalsecrets.external-secrets.io
  9. spec:
  10. group: external-secrets.io
  11. names:
  12. categories:
  13. - external-secrets
  14. kind: ExternalSecret
  15. listKind: ExternalSecretList
  16. plural: externalsecrets
  17. shortNames:
  18. - es
  19. singular: externalsecret
  20. scope: Namespaced
  21. versions:
  22. - additionalPrinterColumns:
  23. - jsonPath: .spec.secretStoreRef.kind
  24. name: StoreType
  25. type: string
  26. - jsonPath: .spec.secretStoreRef.name
  27. name: Store
  28. type: string
  29. - jsonPath: .spec.refreshInterval
  30. name: Refresh Interval
  31. type: string
  32. - jsonPath: .status.conditions[?(@.type=="Ready")].reason
  33. name: Status
  34. type: string
  35. - jsonPath: .status.conditions[?(@.type=="Ready")].status
  36. name: Ready
  37. type: string
  38. - jsonPath: .status.refreshTime
  39. name: Last Sync
  40. type: date
  41. name: v1
  42. schema:
  43. openAPIV3Schema:
  44. description: |-
  45. ExternalSecret is the Schema for the external-secrets API.
  46. It defines how to fetch data from external APIs and make it available as Kubernetes Secrets.
  47. properties:
  48. apiVersion:
  49. description: |-
  50. APIVersion defines the versioned schema of this representation of an object.
  51. Servers should convert recognized schemas to the latest internal value, and
  52. may reject unrecognized values.
  53. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
  54. type: string
  55. kind:
  56. description: |-
  57. Kind is a string value representing the REST resource this object represents.
  58. Servers may infer this from the endpoint the client submits requests to.
  59. Cannot be updated.
  60. In CamelCase.
  61. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
  62. type: string
  63. metadata:
  64. type: object
  65. spec:
  66. description: ExternalSecretSpec defines the desired state of ExternalSecret.
  67. properties:
  68. data:
  69. description: Data defines the connection between the Kubernetes Secret
  70. keys and the Provider data
  71. items:
  72. description: ExternalSecretData defines the connection between the
  73. Kubernetes Secret key (spec.data.<key>) and the Provider data.
  74. properties:
  75. remoteRef:
  76. description: |-
  77. RemoteRef points to the remote secret and defines
  78. which secret (version/property/..) to fetch.
  79. properties:
  80. conversionStrategy:
  81. default: Default
  82. description: Used to define a conversion Strategy
  83. enum:
  84. - Default
  85. - Unicode
  86. type: string
  87. decodingStrategy:
  88. default: None
  89. description: Used to define a decoding Strategy
  90. enum:
  91. - Auto
  92. - Base64
  93. - Base64URL
  94. - None
  95. type: string
  96. key:
  97. description: Key is the key used in the Provider, mandatory
  98. type: string
  99. metadataPolicy:
  100. default: None
  101. description: Policy for fetching tags/labels from provider
  102. secrets, possible options are Fetch, None. Defaults to
  103. None
  104. enum:
  105. - None
  106. - Fetch
  107. type: string
  108. nullBytePolicy:
  109. default: Ignore
  110. description: Controls how ESO handles fetched secret data
  111. containing NUL bytes for this source.
  112. enum:
  113. - Ignore
  114. - Fail
  115. type: string
  116. property:
  117. description: Used to select a specific property of the Provider
  118. value (if a map), if supported
  119. type: string
  120. version:
  121. description: Used to select a specific version of the Provider
  122. value, if supported
  123. type: string
  124. required:
  125. - key
  126. type: object
  127. secretKey:
  128. description: The key in the Kubernetes Secret to store the value.
  129. maxLength: 253
  130. minLength: 1
  131. pattern: ^[-._a-zA-Z0-9]+$
  132. type: string
  133. sourceRef:
  134. description: |-
  135. SourceRef allows you to override the source
  136. from which the value will be pulled.
  137. maxProperties: 1
  138. minProperties: 1
  139. properties:
  140. generatorRef:
  141. description: |-
  142. GeneratorRef points to a generator custom resource.
  143. Deprecated: The generatorRef is not implemented in .data[].
  144. this will be removed with v1.
  145. properties:
  146. apiVersion:
  147. default: generators.external-secrets.io/v1alpha1
  148. description: Specify the apiVersion of the generator
  149. resource
  150. type: string
  151. kind:
  152. description: Specify the Kind of the generator resource
  153. enum:
  154. - ACRAccessToken
  155. - ClusterGenerator
  156. - CloudsmithAccessToken
  157. - ECRAuthorizationToken
  158. - Fake
  159. - GCRAccessToken
  160. - GithubAccessToken
  161. - QuayAccessToken
  162. - Password
  163. - SSHKey
  164. - STSSessionToken
  165. - UUID
  166. - VaultDynamicSecret
  167. - Webhook
  168. - Grafana
  169. - MFA
  170. type: string
  171. name:
  172. description: Specify the name of the generator resource
  173. maxLength: 253
  174. minLength: 1
  175. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  176. type: string
  177. required:
  178. - kind
  179. - name
  180. type: object
  181. storeRef:
  182. description: SecretStoreRef defines which SecretStore to
  183. fetch the ExternalSecret data.
  184. properties:
  185. kind:
  186. description: |-
  187. Kind of the SecretStore resource (SecretStore or ClusterSecretStore)
  188. Defaults to `SecretStore`
  189. enum:
  190. - SecretStore
  191. - ClusterSecretStore
  192. type: string
  193. name:
  194. description: Name of the SecretStore resource
  195. maxLength: 253
  196. minLength: 1
  197. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  198. type: string
  199. type: object
  200. type: object
  201. required:
  202. - remoteRef
  203. - secretKey
  204. type: object
  205. type: array
  206. dataFrom:
  207. description: |-
  208. DataFrom is used to fetch all properties from a specific Provider data
  209. If multiple entries are specified, the Secret keys are merged in the specified order
  210. items:
  211. description: |-
  212. ExternalSecretDataFromRemoteRef defines the connection between the Kubernetes Secret keys and the Provider data
  213. when using DataFrom to fetch multiple values from a Provider.
  214. properties:
  215. extract:
  216. description: |-
  217. Used to extract multiple key/value pairs from one secret
  218. Note: Extract does not support sourceRef.Generator or sourceRef.GeneratorRef.
  219. properties:
  220. conversionStrategy:
  221. default: Default
  222. description: Used to define a conversion Strategy
  223. enum:
  224. - Default
  225. - Unicode
  226. type: string
  227. decodingStrategy:
  228. default: None
  229. description: Used to define a decoding Strategy
  230. enum:
  231. - Auto
  232. - Base64
  233. - Base64URL
  234. - None
  235. type: string
  236. key:
  237. description: Key is the key used in the Provider, mandatory
  238. type: string
  239. metadataPolicy:
  240. default: None
  241. description: Policy for fetching tags/labels from provider
  242. secrets, possible options are Fetch, None. Defaults to
  243. None
  244. enum:
  245. - None
  246. - Fetch
  247. type: string
  248. nullBytePolicy:
  249. default: Ignore
  250. description: Controls how ESO handles fetched secret data
  251. containing NUL bytes for this source.
  252. enum:
  253. - Ignore
  254. - Fail
  255. type: string
  256. property:
  257. description: Used to select a specific property of the Provider
  258. value (if a map), if supported
  259. type: string
  260. version:
  261. description: Used to select a specific version of the Provider
  262. value, if supported
  263. type: string
  264. required:
  265. - key
  266. type: object
  267. find:
  268. description: |-
  269. Used to find secrets based on tags or regular expressions
  270. Note: Find does not support sourceRef.Generator or sourceRef.GeneratorRef.
  271. properties:
  272. conversionStrategy:
  273. default: Default
  274. description: Used to define a conversion Strategy
  275. enum:
  276. - Default
  277. - Unicode
  278. type: string
  279. decodingStrategy:
  280. default: None
  281. description: Used to define a decoding Strategy
  282. enum:
  283. - Auto
  284. - Base64
  285. - Base64URL
  286. - None
  287. type: string
  288. name:
  289. description: Finds secrets based on the name.
  290. properties:
  291. regexp:
  292. description: Finds secrets base
  293. type: string
  294. type: object
  295. nullBytePolicy:
  296. default: Ignore
  297. description: Controls how ESO handles fetched secret data
  298. containing NUL bytes for this find source.
  299. enum:
  300. - Ignore
  301. - Fail
  302. type: string
  303. path:
  304. description: A root path to start the find operations.
  305. type: string
  306. tags:
  307. additionalProperties:
  308. type: string
  309. description: Find secrets based on tags.
  310. type: object
  311. type: object
  312. rewrite:
  313. description: |-
  314. Used to rewrite secret Keys after getting them from the secret Provider
  315. Multiple Rewrite operations can be provided. They are applied in a layered order (first to last)
  316. items:
  317. description: ExternalSecretRewrite defines how to rewrite
  318. secret data values before they are written to the Secret.
  319. maxProperties: 1
  320. minProperties: 1
  321. properties:
  322. merge:
  323. description: |-
  324. Used to merge key/values in one single Secret
  325. The resulting key will contain all values from the specified secrets
  326. properties:
  327. conflictPolicy:
  328. default: Error
  329. description: Used to define the policy to use in conflict
  330. resolution.
  331. enum:
  332. - Ignore
  333. - Error
  334. type: string
  335. into:
  336. default: ""
  337. description: |-
  338. Used to define the target key of the merge operation.
  339. Required if strategy is JSON. Ignored otherwise.
  340. type: string
  341. priority:
  342. description: Used to define key priority in conflict
  343. resolution.
  344. items:
  345. type: string
  346. type: array
  347. priorityPolicy:
  348. default: Strict
  349. description: Used to define the policy when a key
  350. in the priority list does not exist in the input.
  351. enum:
  352. - IgnoreNotFound
  353. - Strict
  354. type: string
  355. strategy:
  356. default: Extract
  357. description: Used to define the strategy to use in
  358. the merge operation.
  359. enum:
  360. - Extract
  361. - JSON
  362. type: string
  363. type: object
  364. regexp:
  365. description: |-
  366. Used to rewrite with regular expressions.
  367. The resulting key will be the output of a regexp.ReplaceAll operation.
  368. properties:
  369. source:
  370. description: Used to define the regular expression
  371. of a re.Compiler.
  372. type: string
  373. target:
  374. description: Used to define the target pattern of
  375. a ReplaceAll operation.
  376. type: string
  377. required:
  378. - source
  379. - target
  380. type: object
  381. transform:
  382. description: |-
  383. Used to apply string transformation on the secrets.
  384. The resulting key will be the output of the template applied by the operation.
  385. properties:
  386. template:
  387. description: |-
  388. Used to define the template to apply on the secret name.
  389. `.value ` will specify the secret name in the template.
  390. type: string
  391. required:
  392. - template
  393. type: object
  394. type: object
  395. type: array
  396. sourceRef:
  397. description: |-
  398. SourceRef points to a store or generator
  399. which contains secret values ready to use.
  400. Use this in combination with Extract or Find pull values out of
  401. a specific SecretStore.
  402. When sourceRef points to a generator Extract or Find is not supported.
  403. The generator returns a static map of values
  404. maxProperties: 1
  405. minProperties: 1
  406. properties:
  407. generatorRef:
  408. description: GeneratorRef points to a generator custom resource.
  409. properties:
  410. apiVersion:
  411. default: generators.external-secrets.io/v1alpha1
  412. description: Specify the apiVersion of the generator
  413. resource
  414. type: string
  415. kind:
  416. description: Specify the Kind of the generator resource
  417. enum:
  418. - ACRAccessToken
  419. - ClusterGenerator
  420. - CloudsmithAccessToken
  421. - ECRAuthorizationToken
  422. - Fake
  423. - GCRAccessToken
  424. - GithubAccessToken
  425. - QuayAccessToken
  426. - Password
  427. - SSHKey
  428. - STSSessionToken
  429. - UUID
  430. - VaultDynamicSecret
  431. - Webhook
  432. - Grafana
  433. - MFA
  434. type: string
  435. name:
  436. description: Specify the name of the generator resource
  437. maxLength: 253
  438. minLength: 1
  439. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  440. type: string
  441. required:
  442. - kind
  443. - name
  444. type: object
  445. storeRef:
  446. description: SecretStoreRef defines which SecretStore to
  447. fetch the ExternalSecret data.
  448. properties:
  449. kind:
  450. description: |-
  451. Kind of the SecretStore resource (SecretStore or ClusterSecretStore)
  452. Defaults to `SecretStore`
  453. enum:
  454. - SecretStore
  455. - ClusterSecretStore
  456. type: string
  457. name:
  458. description: Name of the SecretStore resource
  459. maxLength: 253
  460. minLength: 1
  461. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  462. type: string
  463. type: object
  464. type: object
  465. type: object
  466. type: array
  467. refreshInterval:
  468. default: 1h0m0s
  469. description: |-
  470. RefreshInterval is the amount of time before the values are read again from the SecretStore provider,
  471. specified as Golang Duration strings.
  472. Valid time units are "ns", "us" (or "µs"), "ms", "s", "m", "h"
  473. Example values: "1h0m0s", "2h30m0s", "10m0s"
  474. May be set to "0s" to fetch and create it once. Defaults to 1h0m0s.
  475. type: string
  476. refreshPolicy:
  477. description: |-
  478. RefreshPolicy determines how the ExternalSecret should be refreshed:
  479. - CreatedOnce: Creates the Secret only if it does not exist and does not update it thereafter
  480. - Periodic: Synchronizes the Secret from the external source at regular intervals specified by refreshInterval.
  481. No periodic updates occur if refreshInterval is 0.
  482. - OnChange: Only synchronizes the Secret when the ExternalSecret's metadata or specification changes
  483. enum:
  484. - CreatedOnce
  485. - Periodic
  486. - OnChange
  487. type: string
  488. secretStoreRef:
  489. description: SecretStoreRef defines which SecretStore to fetch the
  490. ExternalSecret data.
  491. properties:
  492. kind:
  493. description: |-
  494. Kind of the SecretStore resource (SecretStore or ClusterSecretStore)
  495. Defaults to `SecretStore`
  496. enum:
  497. - SecretStore
  498. - ClusterSecretStore
  499. type: string
  500. name:
  501. description: Name of the SecretStore resource
  502. maxLength: 253
  503. minLength: 1
  504. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  505. type: string
  506. type: object
  507. target:
  508. default:
  509. creationPolicy: Owner
  510. deletionPolicy: Retain
  511. description: |-
  512. ExternalSecretTarget defines the Kubernetes Secret to be created,
  513. there can be only one target per ExternalSecret.
  514. properties:
  515. creationPolicy:
  516. default: Owner
  517. description: |-
  518. CreationPolicy defines rules on how to create the resulting Secret.
  519. Defaults to "Owner"
  520. enum:
  521. - Owner
  522. - Orphan
  523. - Merge
  524. - None
  525. type: string
  526. deletionPolicy:
  527. default: Retain
  528. description: |-
  529. DeletionPolicy defines rules on how to delete the resulting Secret.
  530. Defaults to "Retain"
  531. enum:
  532. - Delete
  533. - Merge
  534. - Retain
  535. type: string
  536. immutable:
  537. description: Immutable defines if the final secret will be immutable
  538. type: boolean
  539. manifest:
  540. description: |-
  541. Manifest defines a custom Kubernetes resource to create instead of a Secret.
  542. When specified, ExternalSecret will create the resource type defined here
  543. (e.g., ConfigMap, Custom Resource) instead of a Secret.
  544. Warning: Using Generic target. Make sure access policies and encryption are properly configured.
  545. properties:
  546. apiVersion:
  547. description: APIVersion of the target resource (e.g., "v1"
  548. for ConfigMap, "argoproj.io/v1alpha1" for ArgoCD Application)
  549. minLength: 1
  550. type: string
  551. kind:
  552. description: Kind of the target resource (e.g., "ConfigMap",
  553. "Application")
  554. minLength: 1
  555. type: string
  556. required:
  557. - apiVersion
  558. - kind
  559. type: object
  560. name:
  561. description: |-
  562. The name of the Secret resource to be managed.
  563. Defaults to the .metadata.name of the ExternalSecret resource
  564. maxLength: 253
  565. minLength: 1
  566. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  567. type: string
  568. template:
  569. description: Template defines a blueprint for the created Secret
  570. resource.
  571. properties:
  572. data:
  573. additionalProperties:
  574. type: string
  575. type: object
  576. engineVersion:
  577. default: v2
  578. description: |-
  579. EngineVersion specifies the template engine version
  580. that should be used to compile/execute the
  581. template specified in .data and .templateFrom[].
  582. enum:
  583. - v2
  584. type: string
  585. mergePolicy:
  586. default: Replace
  587. description: TemplateMergePolicy defines how the rendered
  588. template should be merged with the existing Secret data.
  589. enum:
  590. - Replace
  591. - Merge
  592. type: string
  593. metadata:
  594. description: ExternalSecretTemplateMetadata defines metadata
  595. fields for the Secret blueprint.
  596. properties:
  597. annotations:
  598. additionalProperties:
  599. type: string
  600. type: object
  601. finalizers:
  602. items:
  603. type: string
  604. type: array
  605. labels:
  606. additionalProperties:
  607. type: string
  608. type: object
  609. type: object
  610. templateFrom:
  611. items:
  612. description: |-
  613. TemplateFrom specifies a source for templates.
  614. Each item in the list can either reference a ConfigMap or a Secret resource.
  615. properties:
  616. configMap:
  617. description: TemplateRef specifies a reference to either
  618. a ConfigMap or a Secret resource.
  619. properties:
  620. items:
  621. description: A list of keys in the ConfigMap/Secret
  622. to use as templates for Secret data
  623. items:
  624. description: TemplateRefItem specifies a key in
  625. the ConfigMap/Secret to use as a template for
  626. Secret data.
  627. properties:
  628. key:
  629. description: A key in the ConfigMap/Secret
  630. maxLength: 253
  631. minLength: 1
  632. pattern: ^[-._a-zA-Z0-9]+$
  633. type: string
  634. templateAs:
  635. default: Values
  636. description: TemplateScope specifies how the
  637. template keys should be interpreted.
  638. enum:
  639. - Values
  640. - KeysAndValues
  641. type: string
  642. required:
  643. - key
  644. type: object
  645. type: array
  646. name:
  647. description: The name of the ConfigMap/Secret resource
  648. maxLength: 253
  649. minLength: 1
  650. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  651. type: string
  652. required:
  653. - items
  654. - name
  655. type: object
  656. literal:
  657. type: string
  658. secret:
  659. description: TemplateRef specifies a reference to either
  660. a ConfigMap or a Secret resource.
  661. properties:
  662. items:
  663. description: A list of keys in the ConfigMap/Secret
  664. to use as templates for Secret data
  665. items:
  666. description: TemplateRefItem specifies a key in
  667. the ConfigMap/Secret to use as a template for
  668. Secret data.
  669. properties:
  670. key:
  671. description: A key in the ConfigMap/Secret
  672. maxLength: 253
  673. minLength: 1
  674. pattern: ^[-._a-zA-Z0-9]+$
  675. type: string
  676. templateAs:
  677. default: Values
  678. description: TemplateScope specifies how the
  679. template keys should be interpreted.
  680. enum:
  681. - Values
  682. - KeysAndValues
  683. type: string
  684. required:
  685. - key
  686. type: object
  687. type: array
  688. name:
  689. description: The name of the ConfigMap/Secret resource
  690. maxLength: 253
  691. minLength: 1
  692. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  693. type: string
  694. required:
  695. - items
  696. - name
  697. type: object
  698. target:
  699. default: Data
  700. description: |-
  701. Target specifies where to place the template result.
  702. For Secret resources, common values are: "Data", "Annotations", "Labels".
  703. For custom resources (when spec.target.manifest is set), this supports
  704. nested paths like "spec.database.config" or "data".
  705. type: string
  706. type: object
  707. type: array
  708. type:
  709. type: string
  710. type: object
  711. type: object
  712. type: object
  713. status:
  714. description: ExternalSecretStatus defines the observed state of ExternalSecret.
  715. properties:
  716. binding:
  717. description: Binding represents a servicebinding.io Provisioned Service
  718. reference to the secret
  719. properties:
  720. name:
  721. default: ""
  722. description: |-
  723. Name of the referent.
  724. This field is effectively required, but due to backwards compatibility is
  725. allowed to be empty. Instances of this type with an empty value here are
  726. almost certainly wrong.
  727. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
  728. type: string
  729. type: object
  730. x-kubernetes-map-type: atomic
  731. conditions:
  732. items:
  733. description: ExternalSecretStatusCondition defines a status condition
  734. of an ExternalSecret resource.
  735. properties:
  736. lastTransitionTime:
  737. format: date-time
  738. type: string
  739. message:
  740. type: string
  741. reason:
  742. type: string
  743. status:
  744. type: string
  745. type:
  746. description: ExternalSecretConditionType defines a value type
  747. for ExternalSecret conditions.
  748. enum:
  749. - Ready
  750. - Deleted
  751. type: string
  752. required:
  753. - status
  754. - type
  755. type: object
  756. type: array
  757. refreshTime:
  758. description: |-
  759. refreshTime is the time and date the external secret was fetched and
  760. the target secret updated
  761. format: date-time
  762. nullable: true
  763. type: string
  764. syncedResourceVersion:
  765. description: SyncedResourceVersion keeps track of the last synced
  766. version
  767. type: string
  768. type: object
  769. type: object
  770. selectableFields:
  771. - jsonPath: .spec.secretStoreRef.name
  772. - jsonPath: .spec.secretStoreRef.kind
  773. - jsonPath: .spec.target.name
  774. - jsonPath: .spec.refreshInterval
  775. served: true
  776. storage: true
  777. subresources:
  778. status: {}
  779. - additionalPrinterColumns:
  780. - jsonPath: .spec.secretStoreRef.kind
  781. name: StoreType
  782. type: string
  783. - jsonPath: .spec.secretStoreRef.name
  784. name: Store
  785. type: string
  786. - jsonPath: .spec.refreshInterval
  787. name: Refresh Interval
  788. type: string
  789. - jsonPath: .status.conditions[?(@.type=="Ready")].reason
  790. name: Status
  791. type: string
  792. - jsonPath: .status.conditions[?(@.type=="Ready")].status
  793. name: Ready
  794. type: string
  795. - jsonPath: .status.refreshTime
  796. name: Last Sync
  797. type: date
  798. deprecated: true
  799. name: v1beta1
  800. schema:
  801. openAPIV3Schema:
  802. description: ExternalSecret is the schema for the external-secrets API.
  803. properties:
  804. apiVersion:
  805. description: |-
  806. APIVersion defines the versioned schema of this representation of an object.
  807. Servers should convert recognized schemas to the latest internal value, and
  808. may reject unrecognized values.
  809. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
  810. type: string
  811. kind:
  812. description: |-
  813. Kind is a string value representing the REST resource this object represents.
  814. Servers may infer this from the endpoint the client submits requests to.
  815. Cannot be updated.
  816. In CamelCase.
  817. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
  818. type: string
  819. metadata:
  820. type: object
  821. spec:
  822. description: ExternalSecretSpec defines the desired state of ExternalSecret.
  823. properties:
  824. data:
  825. description: Data defines the connection between the Kubernetes Secret
  826. keys and the Provider data
  827. items:
  828. description: ExternalSecretData defines the connection between the
  829. Kubernetes Secret key (spec.data.<key>) and the Provider data.
  830. properties:
  831. remoteRef:
  832. description: |-
  833. RemoteRef points to the remote secret and defines
  834. which secret (version/property/..) to fetch.
  835. properties:
  836. conversionStrategy:
  837. default: Default
  838. description: Used to define a conversion Strategy
  839. enum:
  840. - Default
  841. - Unicode
  842. type: string
  843. decodingStrategy:
  844. default: None
  845. description: Used to define a decoding Strategy
  846. enum:
  847. - Auto
  848. - Base64
  849. - Base64URL
  850. - None
  851. type: string
  852. key:
  853. description: Key is the key used in the Provider, mandatory
  854. type: string
  855. metadataPolicy:
  856. default: None
  857. description: Policy for fetching tags/labels from provider
  858. secrets, possible options are Fetch, None. Defaults to
  859. None
  860. enum:
  861. - None
  862. - Fetch
  863. type: string
  864. property:
  865. description: Used to select a specific property of the Provider
  866. value (if a map), if supported
  867. type: string
  868. version:
  869. description: Used to select a specific version of the Provider
  870. value, if supported
  871. type: string
  872. required:
  873. - key
  874. type: object
  875. secretKey:
  876. description: The key in the Kubernetes Secret to store the value.
  877. maxLength: 253
  878. minLength: 1
  879. pattern: ^[-._a-zA-Z0-9]+$
  880. type: string
  881. sourceRef:
  882. description: |-
  883. SourceRef allows you to override the source
  884. from which the value will be pulled.
  885. maxProperties: 1
  886. minProperties: 1
  887. properties:
  888. generatorRef:
  889. description: |-
  890. GeneratorRef points to a generator custom resource.
  891. Deprecated: The generatorRef is not implemented in .data[].
  892. this will be removed with v1.
  893. properties:
  894. apiVersion:
  895. default: generators.external-secrets.io/v1alpha1
  896. description: Specify the apiVersion of the generator
  897. resource
  898. type: string
  899. kind:
  900. description: Specify the Kind of the generator resource
  901. enum:
  902. - ACRAccessToken
  903. - ClusterGenerator
  904. - ECRAuthorizationToken
  905. - Fake
  906. - GCRAccessToken
  907. - GithubAccessToken
  908. - QuayAccessToken
  909. - Password
  910. - SSHKey
  911. - STSSessionToken
  912. - UUID
  913. - VaultDynamicSecret
  914. - Webhook
  915. - Grafana
  916. type: string
  917. name:
  918. description: Specify the name of the generator resource
  919. maxLength: 253
  920. minLength: 1
  921. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  922. type: string
  923. required:
  924. - kind
  925. - name
  926. type: object
  927. storeRef:
  928. description: SecretStoreRef defines which SecretStore to
  929. fetch the ExternalSecret data.
  930. properties:
  931. kind:
  932. description: |-
  933. Kind of the SecretStore resource (SecretStore or ClusterSecretStore)
  934. Defaults to `SecretStore`
  935. enum:
  936. - SecretStore
  937. - ClusterSecretStore
  938. type: string
  939. name:
  940. description: Name of the SecretStore resource
  941. maxLength: 253
  942. minLength: 1
  943. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  944. type: string
  945. type: object
  946. type: object
  947. required:
  948. - remoteRef
  949. - secretKey
  950. type: object
  951. type: array
  952. dataFrom:
  953. description: |-
  954. DataFrom is used to fetch all properties from a specific Provider data
  955. If multiple entries are specified, the Secret keys are merged in the specified order
  956. items:
  957. description: ExternalSecretDataFromRemoteRef defines a reference
  958. to multiple secrets in the provider to be fetched using options.
  959. properties:
  960. extract:
  961. description: |-
  962. Used to extract multiple key/value pairs from one secret
  963. Note: Extract does not support sourceRef.Generator or sourceRef.GeneratorRef.
  964. properties:
  965. conversionStrategy:
  966. default: Default
  967. description: Used to define a conversion Strategy
  968. enum:
  969. - Default
  970. - Unicode
  971. type: string
  972. decodingStrategy:
  973. default: None
  974. description: Used to define a decoding Strategy
  975. enum:
  976. - Auto
  977. - Base64
  978. - Base64URL
  979. - None
  980. type: string
  981. key:
  982. description: Key is the key used in the Provider, mandatory
  983. type: string
  984. metadataPolicy:
  985. default: None
  986. description: Policy for fetching tags/labels from provider
  987. secrets, possible options are Fetch, None. Defaults to
  988. None
  989. enum:
  990. - None
  991. - Fetch
  992. type: string
  993. property:
  994. description: Used to select a specific property of the Provider
  995. value (if a map), if supported
  996. type: string
  997. version:
  998. description: Used to select a specific version of the Provider
  999. value, if supported
  1000. type: string
  1001. required:
  1002. - key
  1003. type: object
  1004. find:
  1005. description: |-
  1006. Used to find secrets based on tags or regular expressions
  1007. Note: Find does not support sourceRef.Generator or sourceRef.GeneratorRef.
  1008. properties:
  1009. conversionStrategy:
  1010. default: Default
  1011. description: Used to define a conversion Strategy
  1012. enum:
  1013. - Default
  1014. - Unicode
  1015. type: string
  1016. decodingStrategy:
  1017. default: None
  1018. description: Used to define a decoding Strategy
  1019. enum:
  1020. - Auto
  1021. - Base64
  1022. - Base64URL
  1023. - None
  1024. type: string
  1025. name:
  1026. description: Finds secrets based on the name.
  1027. properties:
  1028. regexp:
  1029. description: Finds secrets base
  1030. type: string
  1031. type: object
  1032. path:
  1033. description: A root path to start the find operations.
  1034. type: string
  1035. tags:
  1036. additionalProperties:
  1037. type: string
  1038. description: Find secrets based on tags.
  1039. type: object
  1040. type: object
  1041. rewrite:
  1042. description: |-
  1043. Used to rewrite secret Keys after getting them from the secret Provider
  1044. Multiple Rewrite operations can be provided. They are applied in a layered order (first to last)
  1045. items:
  1046. description: ExternalSecretRewrite defines rules on how to
  1047. rewrite secret keys.
  1048. maxProperties: 1
  1049. minProperties: 1
  1050. properties:
  1051. regexp:
  1052. description: |-
  1053. Used to rewrite with regular expressions.
  1054. The resulting key will be the output of a regexp.ReplaceAll operation.
  1055. properties:
  1056. source:
  1057. description: Used to define the regular expression
  1058. of a re.Compiler.
  1059. type: string
  1060. target:
  1061. description: Used to define the target pattern of
  1062. a ReplaceAll operation.
  1063. type: string
  1064. required:
  1065. - source
  1066. - target
  1067. type: object
  1068. transform:
  1069. description: |-
  1070. Used to apply string transformation on the secrets.
  1071. The resulting key will be the output of the template applied by the operation.
  1072. properties:
  1073. template:
  1074. description: |-
  1075. Used to define the template to apply on the secret name.
  1076. `.value ` will specify the secret name in the template.
  1077. type: string
  1078. required:
  1079. - template
  1080. type: object
  1081. type: object
  1082. type: array
  1083. sourceRef:
  1084. description: |-
  1085. SourceRef points to a store or generator
  1086. which contains secret values ready to use.
  1087. Use this in combination with Extract or Find pull values out of
  1088. a specific SecretStore.
  1089. When sourceRef points to a generator Extract or Find is not supported.
  1090. The generator returns a static map of values
  1091. maxProperties: 1
  1092. minProperties: 1
  1093. properties:
  1094. generatorRef:
  1095. description: GeneratorRef points to a generator custom resource.
  1096. properties:
  1097. apiVersion:
  1098. default: generators.external-secrets.io/v1alpha1
  1099. description: Specify the apiVersion of the generator
  1100. resource
  1101. type: string
  1102. kind:
  1103. description: Specify the Kind of the generator resource
  1104. enum:
  1105. - ACRAccessToken
  1106. - ClusterGenerator
  1107. - ECRAuthorizationToken
  1108. - Fake
  1109. - GCRAccessToken
  1110. - GithubAccessToken
  1111. - QuayAccessToken
  1112. - Password
  1113. - SSHKey
  1114. - STSSessionToken
  1115. - UUID
  1116. - VaultDynamicSecret
  1117. - Webhook
  1118. - Grafana
  1119. type: string
  1120. name:
  1121. description: Specify the name of the generator resource
  1122. maxLength: 253
  1123. minLength: 1
  1124. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  1125. type: string
  1126. required:
  1127. - kind
  1128. - name
  1129. type: object
  1130. storeRef:
  1131. description: SecretStoreRef defines which SecretStore to
  1132. fetch the ExternalSecret data.
  1133. properties:
  1134. kind:
  1135. description: |-
  1136. Kind of the SecretStore resource (SecretStore or ClusterSecretStore)
  1137. Defaults to `SecretStore`
  1138. enum:
  1139. - SecretStore
  1140. - ClusterSecretStore
  1141. type: string
  1142. name:
  1143. description: Name of the SecretStore resource
  1144. maxLength: 253
  1145. minLength: 1
  1146. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  1147. type: string
  1148. type: object
  1149. type: object
  1150. type: object
  1151. type: array
  1152. refreshInterval:
  1153. default: 1h0m0s
  1154. description: |-
  1155. RefreshInterval is the amount of time before the values are read again from the SecretStore provider,
  1156. specified as Golang Duration strings.
  1157. Valid time units are "ns", "us" (or "µs"), "ms", "s", "m", "h"
  1158. Example values: "1h0m0s", "2h30m0s", "10m0s"
  1159. May be set to "0s" to fetch and create it once. Defaults to 1h0m0s.
  1160. type: string
  1161. refreshPolicy:
  1162. description: |-
  1163. RefreshPolicy determines how the ExternalSecret should be refreshed:
  1164. - CreatedOnce: Creates the Secret only if it does not exist and does not update it thereafter
  1165. - Periodic: Synchronizes the Secret from the external source at regular intervals specified by refreshInterval.
  1166. No periodic updates occur if refreshInterval is 0.
  1167. - OnChange: Only synchronizes the Secret when the ExternalSecret's metadata or specification changes
  1168. enum:
  1169. - CreatedOnce
  1170. - Periodic
  1171. - OnChange
  1172. type: string
  1173. secretStoreRef:
  1174. description: SecretStoreRef defines which SecretStore to fetch the
  1175. ExternalSecret data.
  1176. properties:
  1177. kind:
  1178. description: |-
  1179. Kind of the SecretStore resource (SecretStore or ClusterSecretStore)
  1180. Defaults to `SecretStore`
  1181. enum:
  1182. - SecretStore
  1183. - ClusterSecretStore
  1184. type: string
  1185. name:
  1186. description: Name of the SecretStore resource
  1187. maxLength: 253
  1188. minLength: 1
  1189. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  1190. type: string
  1191. type: object
  1192. target:
  1193. default:
  1194. creationPolicy: Owner
  1195. deletionPolicy: Retain
  1196. description: |-
  1197. ExternalSecretTarget defines the Kubernetes Secret to be created
  1198. There can be only one target per ExternalSecret.
  1199. properties:
  1200. creationPolicy:
  1201. default: Owner
  1202. description: |-
  1203. CreationPolicy defines rules on how to create the resulting Secret.
  1204. Defaults to "Owner"
  1205. enum:
  1206. - Owner
  1207. - Orphan
  1208. - Merge
  1209. - None
  1210. type: string
  1211. deletionPolicy:
  1212. default: Retain
  1213. description: |-
  1214. DeletionPolicy defines rules on how to delete the resulting Secret.
  1215. Defaults to "Retain"
  1216. enum:
  1217. - Delete
  1218. - Merge
  1219. - Retain
  1220. type: string
  1221. immutable:
  1222. description: Immutable defines if the final secret will be immutable
  1223. type: boolean
  1224. name:
  1225. description: |-
  1226. The name of the Secret resource to be managed.
  1227. Defaults to the .metadata.name of the ExternalSecret resource
  1228. maxLength: 253
  1229. minLength: 1
  1230. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  1231. type: string
  1232. template:
  1233. description: Template defines a blueprint for the created Secret
  1234. resource.
  1235. properties:
  1236. data:
  1237. additionalProperties:
  1238. type: string
  1239. type: object
  1240. engineVersion:
  1241. default: v2
  1242. description: |-
  1243. EngineVersion specifies the template engine version
  1244. that should be used to compile/execute the
  1245. template specified in .data and .templateFrom[].
  1246. enum:
  1247. - v2
  1248. type: string
  1249. mergePolicy:
  1250. default: Replace
  1251. description: TemplateMergePolicy defines how template values
  1252. should be merged when generating a secret.
  1253. enum:
  1254. - Replace
  1255. - Merge
  1256. type: string
  1257. metadata:
  1258. description: ExternalSecretTemplateMetadata defines metadata
  1259. fields for the Secret blueprint.
  1260. properties:
  1261. annotations:
  1262. additionalProperties:
  1263. type: string
  1264. type: object
  1265. labels:
  1266. additionalProperties:
  1267. type: string
  1268. type: object
  1269. type: object
  1270. templateFrom:
  1271. items:
  1272. description: TemplateFrom defines a source for template
  1273. data.
  1274. properties:
  1275. configMap:
  1276. description: TemplateRef defines a reference to a template
  1277. source in a ConfigMap or Secret.
  1278. properties:
  1279. items:
  1280. description: A list of keys in the ConfigMap/Secret
  1281. to use as templates for Secret data
  1282. items:
  1283. description: TemplateRefItem defines which key
  1284. in the referenced ConfigMap or Secret to use
  1285. as a template.
  1286. properties:
  1287. key:
  1288. description: A key in the ConfigMap/Secret
  1289. maxLength: 253
  1290. minLength: 1
  1291. pattern: ^[-._a-zA-Z0-9]+$
  1292. type: string
  1293. templateAs:
  1294. default: Values
  1295. description: TemplateScope defines the scope
  1296. of the template when processing template
  1297. data.
  1298. enum:
  1299. - Values
  1300. - KeysAndValues
  1301. type: string
  1302. required:
  1303. - key
  1304. type: object
  1305. type: array
  1306. name:
  1307. description: The name of the ConfigMap/Secret resource
  1308. maxLength: 253
  1309. minLength: 1
  1310. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  1311. type: string
  1312. required:
  1313. - items
  1314. - name
  1315. type: object
  1316. literal:
  1317. type: string
  1318. secret:
  1319. description: TemplateRef defines a reference to a template
  1320. source in a ConfigMap or Secret.
  1321. properties:
  1322. items:
  1323. description: A list of keys in the ConfigMap/Secret
  1324. to use as templates for Secret data
  1325. items:
  1326. description: TemplateRefItem defines which key
  1327. in the referenced ConfigMap or Secret to use
  1328. as a template.
  1329. properties:
  1330. key:
  1331. description: A key in the ConfigMap/Secret
  1332. maxLength: 253
  1333. minLength: 1
  1334. pattern: ^[-._a-zA-Z0-9]+$
  1335. type: string
  1336. templateAs:
  1337. default: Values
  1338. description: TemplateScope defines the scope
  1339. of the template when processing template
  1340. data.
  1341. enum:
  1342. - Values
  1343. - KeysAndValues
  1344. type: string
  1345. required:
  1346. - key
  1347. type: object
  1348. type: array
  1349. name:
  1350. description: The name of the ConfigMap/Secret resource
  1351. maxLength: 253
  1352. minLength: 1
  1353. pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
  1354. type: string
  1355. required:
  1356. - items
  1357. - name
  1358. type: object
  1359. target:
  1360. default: Data
  1361. description: TemplateTarget defines the target field
  1362. where the template result will be stored.
  1363. enum:
  1364. - Data
  1365. - Annotations
  1366. - Labels
  1367. type: string
  1368. type: object
  1369. type: array
  1370. type:
  1371. type: string
  1372. type: object
  1373. type: object
  1374. type: object
  1375. status:
  1376. description: ExternalSecretStatus defines the observed state of ExternalSecret.
  1377. properties:
  1378. binding:
  1379. description: Binding represents a servicebinding.io Provisioned Service
  1380. reference to the secret
  1381. properties:
  1382. name:
  1383. default: ""
  1384. description: |-
  1385. Name of the referent.
  1386. This field is effectively required, but due to backwards compatibility is
  1387. allowed to be empty. Instances of this type with an empty value here are
  1388. almost certainly wrong.
  1389. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
  1390. type: string
  1391. type: object
  1392. x-kubernetes-map-type: atomic
  1393. conditions:
  1394. items:
  1395. description: ExternalSecretStatusCondition contains condition information
  1396. for an ExternalSecret.
  1397. properties:
  1398. lastTransitionTime:
  1399. format: date-time
  1400. type: string
  1401. message:
  1402. type: string
  1403. reason:
  1404. type: string
  1405. status:
  1406. type: string
  1407. type:
  1408. description: ExternalSecretConditionType defines the condition
  1409. type for an ExternalSecret.
  1410. type: string
  1411. required:
  1412. - status
  1413. - type
  1414. type: object
  1415. type: array
  1416. refreshTime:
  1417. description: |-
  1418. refreshTime is the time and date the external secret was fetched and
  1419. the target secret updated
  1420. format: date-time
  1421. nullable: true
  1422. type: string
  1423. syncedResourceVersion:
  1424. description: SyncedResourceVersion keeps track of the last synced
  1425. version
  1426. type: string
  1427. type: object
  1428. type: object
  1429. served: false
  1430. storage: false
  1431. subresources:
  1432. status: {}