03-clusterserviceversion.crd.yaml 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438
  1. ##---
  2. # Source: olm/templates/03-clusterserviceversion.crd.yaml
  3. apiVersion: apiextensions.k8s.io/v1beta1
  4. kind: CustomResourceDefinition
  5. metadata:
  6. name: clusterserviceversions.operators.coreos.com
  7. annotations:
  8. displayName: Operator Version
  9. description: Represents an Operator that should be running on the cluster, including requirements and install strategy.
  10. spec:
  11. names:
  12. plural: clusterserviceversions
  13. singular: clusterserviceversion
  14. kind: ClusterServiceVersion
  15. listKind: ClusterServiceVersionList
  16. shortNames:
  17. - csv
  18. categories:
  19. - all
  20. - olm
  21. additionalPrinterColumns:
  22. - name: Display
  23. type: string
  24. description: The name of the CSV
  25. JSONPath: .spec.displayName
  26. - name: Version
  27. type: string
  28. description: The version of the CSV
  29. JSONPath: .spec.version
  30. - name: Replaces
  31. type: string
  32. description: The name of a CSV that this one replaces
  33. JSONPath: .spec.replaces
  34. - name: Phase
  35. type: string
  36. JSONPath: .status.phase
  37. group: operators.coreos.com
  38. version: v1alpha1
  39. versions:
  40. - name: v1alpha1
  41. served: true
  42. storage: true
  43. scope: Namespaced
  44. subresources:
  45. # status enables the status subresource.
  46. status: {}
  47. validation:
  48. openAPIV3Schema:
  49. properties:
  50. spec:
  51. type: object
  52. description: Spec for a ClusterServiceVersion
  53. required:
  54. - displayName
  55. - install
  56. properties:
  57. displayName:
  58. type: string
  59. description: Human readable name of the application that will be displayed in the ALM UI
  60. description:
  61. type: string
  62. description: Human readable description of what the application does
  63. keywords:
  64. type: array
  65. description: List of keywords which will be used to discover and categorize app types
  66. items:
  67. type: string
  68. maintainers:
  69. type: array
  70. description: Those responsible for the creation of this specific app type
  71. items:
  72. type: object
  73. description: Information for a single maintainer
  74. required:
  75. - name
  76. - email
  77. properties:
  78. name:
  79. type: string
  80. description: Maintainer's name
  81. email:
  82. type: string
  83. description: Maintainer's email address
  84. format: email
  85. optionalProperties:
  86. type: string
  87. description: "Any additional key-value metadata you wish to expose about the maintainer, e.g. github: <username>"
  88. links:
  89. type: array
  90. description: Interesting links to find more information about the project, such as marketing page, documentation, or github page
  91. items:
  92. type: object
  93. description: A single link to describe one aspect of the project
  94. required:
  95. - name
  96. - url
  97. properties:
  98. name:
  99. type: string
  100. description: Name of the link type, e.g. homepage or github url
  101. url:
  102. type: string
  103. description: URL to which the link should point
  104. format: uri
  105. icon:
  106. type: array
  107. description: Icon which should be rendered with the application information
  108. required:
  109. - base64data
  110. - mediatype
  111. properties:
  112. base64data:
  113. type: string
  114. description: Base64 binary representation of the icon image
  115. pattern: ^(?:[A-Za-z0-9+/]{4}){0,16250}(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$
  116. mediatype:
  117. type: string
  118. description: Mediatype for the binary data specified in the base64data property
  119. enum:
  120. - image/gif
  121. - image/jpeg
  122. - image/png
  123. - image/svg+xml
  124. version:
  125. type: string
  126. description: Version string, recommended that users use semantic versioning
  127. pattern: ^(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(-(0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(\.(0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*)?(\+[0-9a-zA-Z-]+(\.[0-9a-zA-Z-]+)*)?$
  128. replaces:
  129. type: string
  130. description: Name of the ClusterServiceVersion custom resource that this version replaces
  131. maturity:
  132. type: string
  133. description: What level of maturity the software has achieved at this version
  134. enum:
  135. - planning
  136. - pre-alpha
  137. - alpha
  138. - beta
  139. - stable
  140. - mature
  141. - inactive
  142. - deprecated
  143. labels:
  144. type: object
  145. description: Labels that will be applied to associated resources created by the operator.
  146. selector:
  147. type: object
  148. description: Label selector to find resources associated with or managed by the operator
  149. properties:
  150. matchLabels:
  151. type: object
  152. description: Label key:value pairs to match directly
  153. matchExpressions:
  154. type: array
  155. description: A set of expressions to match against the resource.
  156. items:
  157. allOf:
  158. - type: object
  159. required:
  160. - key
  161. - operator
  162. - values
  163. properties:
  164. key:
  165. type: string
  166. description: the key to match
  167. operator:
  168. type: string
  169. description: the operator for the expression
  170. enum:
  171. - In
  172. - NotIn
  173. - Exists
  174. - DoesNotExist
  175. values:
  176. type: array
  177. description: set of values for the expression
  178. customresourcedefinitions:
  179. type: object
  180. properties:
  181. owned:
  182. type: array
  183. description: What resources this operator is responsible for managing. No two running operators should manage the same resource.
  184. items:
  185. type: object
  186. required:
  187. - name
  188. - version
  189. - kind
  190. - displayName
  191. - description
  192. properties:
  193. name:
  194. type: string
  195. description: Fully qualified name of the CustomResourceDefinition (e.g. my-resource-v1.app.coreos.com)
  196. version:
  197. type: string
  198. description: The version field of the CustomResourceDefinition
  199. kind:
  200. type: string
  201. description: The kind field of the CustomResourceDefinition
  202. displayName:
  203. type: string
  204. description: A human-readable name for the CRD.
  205. description:
  206. type: string
  207. description: A description of the CRD
  208. resources:
  209. type: array
  210. items:
  211. type: object
  212. description: A list of resources that should be displayed for the CRD
  213. required:
  214. - kind
  215. - version
  216. properties:
  217. name:
  218. type: string
  219. description: If a CRD, the fully qualified name of the CustomResourceDefinition (e.g. my-resource-v1.app.coreos.com)
  220. version:
  221. type: string
  222. description: The version of the resource kind
  223. kind:
  224. type: string
  225. description: The kind field of the resource kind
  226. statusDescriptors:
  227. type: array
  228. items:
  229. type: object
  230. description: A spec for a field in the status block of the CRD
  231. required:
  232. - path
  233. - displayName
  234. - description
  235. properties:
  236. path:
  237. type: string
  238. description: A jsonpath indexing into the status object on the CR where the the status value can be found.
  239. displayName:
  240. type: string
  241. description: A human-readable name for the status entry.
  242. description:
  243. type: string
  244. description: A description of the status entry.
  245. x-descriptors:
  246. type: array
  247. description: A list of descriptors for the status entry that indicate the meaning of the field.
  248. items:
  249. type: string
  250. value:
  251. type: object
  252. description: If present, the value of this status is the same for all instances of the CRD and can be found here instead of on the CR.
  253. specDescriptors:
  254. type: array
  255. items:
  256. type: object
  257. description: A spec for a field in the spec block of the CRD
  258. required:
  259. - path
  260. - displayName
  261. - description
  262. properties:
  263. path:
  264. type: string
  265. description: A jsonpath indexing into the spec object on the CR where the the spec value can be found.
  266. displayName:
  267. type: string
  268. description: A human-readable name for the spec entry.
  269. description:
  270. type: string
  271. description: A description of the spec entry.
  272. x-descriptors:
  273. type: array
  274. description: A list of descriptors for the spec entry that indicate the meaning of the field.
  275. items:
  276. type: string
  277. value:
  278. type: object
  279. description: If present, the value of this spec is the same for all instances of the CRD and can be found here instead of on the CR.
  280. required:
  281. type: array
  282. description: What resources this operator is responsible for managing. No two running operators should manage the same resource.
  283. items:
  284. type: object
  285. required:
  286. - name
  287. - version
  288. - kind
  289. - displayName
  290. - description
  291. properties:
  292. name:
  293. type: string
  294. description: Fully qualified name of the CustomResourceDefinition (e.g. my-resource-v1.app.coreos.com)
  295. version:
  296. type: string
  297. description: The version field of the CustomResourceDefinition
  298. kind:
  299. type: string
  300. description: The kind field of the CustomResourceDefinition
  301. displayName:
  302. type: string
  303. description: A human-readable name for the CRD.
  304. description:
  305. type: string
  306. description: A description of the CRD
  307. statusDescriptors:
  308. type: array
  309. items:
  310. type: object
  311. description: A spec for a field in the status block of the CRD
  312. required:
  313. - path
  314. - displayName
  315. - description
  316. properties:
  317. path:
  318. type: string
  319. description: A jsonpath indexing into the status object on the CR where the the status value can be found.
  320. displayName:
  321. type: string
  322. description: A human-readable name for the status entry.
  323. description:
  324. type: string
  325. description: A description of the status entry.
  326. x-descriptors:
  327. type: array
  328. description: A list of descriptors for the status entry that indicate the meaning of the field.
  329. items:
  330. type: string
  331. value:
  332. type: object
  333. description: If present, the value of this status is the same for all instances of the CRD and can be found here instead of on the CR.
  334. install:
  335. type: object
  336. description: Information required to install this specific version of the operator software
  337. oneOf:
  338. - type: object
  339. required:
  340. - strategy
  341. - spec
  342. properties:
  343. strategy:
  344. type: string
  345. enum: ['image']
  346. spec:
  347. type: object
  348. required:
  349. - image
  350. properties:
  351. image:
  352. type: string
  353. - type: object
  354. required:
  355. - strategy
  356. - spec
  357. properties:
  358. strategy:
  359. type: string
  360. enum: ['deployment']
  361. spec:
  362. type: object
  363. required:
  364. - deployments
  365. properties:
  366. deployments:
  367. type: array
  368. description: List of deployments to create
  369. items:
  370. type: object
  371. description: A name and deployment to create in the cluster
  372. required:
  373. - name
  374. - spec
  375. properties:
  376. name:
  377. type: string
  378. description: the consistent name of the deployment
  379. spec:
  380. type: object
  381. description: The deployment spec to create in the cluster
  382. permissions:
  383. type: array
  384. description: Permissions needed by the deployement to run correctly
  385. items:
  386. type: object
  387. required:
  388. - serviceAccountName
  389. - rules
  390. properties:
  391. serviceAccountName:
  392. type: string
  393. description: The service account name to create for the deployment
  394. rules:
  395. type: array
  396. items:
  397. type: object
  398. description: a rule required by the service account
  399. properties:
  400. apiGroups:
  401. type: array
  402. description: apiGroups the rule applies to
  403. items:
  404. type: string
  405. resources:
  406. type: array
  407. items:
  408. type: string
  409. resourceNames:
  410. type: array
  411. items:
  412. type: string
  413. verbs:
  414. type: array
  415. items:
  416. type: string
  417. enum:
  418. - "*"
  419. - get
  420. - list
  421. - watch
  422. - create
  423. - update
  424. - patch
  425. - delete
  426. - deletecollection
  427. status:
  428. type: object
  429. description: Status for a ClusterServiceVersion