awx_operator.yml 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531
  1. # This file is generated by Ansible. Changes will be lost.
  2. # Update templates under ansible/templates/
  3. ---
  4. apiVersion: apiextensions.k8s.io/v1
  5. kind: CustomResourceDefinition
  6. metadata:
  7. name: awxs.awx.ansible.com
  8. namespace: awx
  9. spec:
  10. group: awx.ansible.com
  11. names:
  12. kind: AWX
  13. listKind: AWXList
  14. plural: awxs
  15. singular: awx
  16. scope: Namespaced
  17. versions:
  18. - name: v1beta1
  19. served: true
  20. storage: true
  21. subresources:
  22. status: {}
  23. schema:
  24. openAPIV3Schema:
  25. description: Schema validation for the AWX CRD
  26. properties:
  27. spec:
  28. properties:
  29. deployment_type:
  30. description: Name of the deployment type
  31. type: string
  32. default: awx
  33. kind:
  34. description: Kind of the deployment type
  35. type: string
  36. default: AWX
  37. api_version:
  38. description: apiVersion of the deployment type
  39. type: string
  40. default: awx.ansible.com/v1beta1
  41. tower_task_privileged:
  42. description: If a privileged security context should be enabled
  43. type: boolean
  44. default: false
  45. tower_admin_user:
  46. description: Username to use for the admin account
  47. type: string
  48. default: admin
  49. tower_hostname:
  50. description: The hostname of the instance
  51. type: string
  52. tower_admin_email:
  53. description: The admin user email
  54. type: string
  55. tower_admin_password_secret:
  56. description: Secret where the admin password can be found
  57. type: string
  58. tower_postgres_configuration_secret:
  59. description: Secret where the database configuration can be found
  60. type: string
  61. tower_old_postgres_configuration_secret:
  62. description: Secret where the old database configuration can be found for data migration
  63. type: string
  64. tower_secret_key_secret:
  65. description: Secret where the secret key can be found
  66. type: string
  67. tower_broadcast_websocket_secret:
  68. description: Secret where the broadcast websocket secret can be found
  69. type: string
  70. tower_extra_volumes:
  71. description: Specify extra volumes to add to the application pod
  72. type: string
  73. tower_ingress_type:
  74. description: The ingress type to use to reach the deployed instance
  75. type: string
  76. enum:
  77. - none
  78. - Ingress
  79. - ingress
  80. - Route
  81. - route
  82. - LoadBalancer
  83. - loadbalancer
  84. - NodePort
  85. - nodeport
  86. tower_ingress_annotations:
  87. description: Annotations to add to the ingress
  88. type: string
  89. tower_ingress_tls_secret:
  90. description: Secret where the ingress TLS secret can be found
  91. type: string
  92. tower_loadbalancer_annotations:
  93. description: Annotations to add to the loadbalancer
  94. type: string
  95. tower_loadbalancer_protocol:
  96. description: Protocol to use for the loadbalancer
  97. type: string
  98. default: http
  99. enum:
  100. - http
  101. - https
  102. tower_loadbalancer_port:
  103. description: Port to use for the loadbalancer
  104. type: integer
  105. default: 80
  106. tower_route_host:
  107. description: The DNS to use to points to the instance
  108. type: string
  109. tower_route_tls_termination_mechanism:
  110. description: The secure TLS termination mechanism to use
  111. type: string
  112. default: Edge
  113. enum:
  114. - Edge
  115. - edge
  116. - Passthrough
  117. - passthrough
  118. tower_route_tls_secret:
  119. description: Secret where the TLS related credentials are stored
  120. type: string
  121. tower_node_selector:
  122. description: nodeSelector for the AWX pods
  123. type: string
  124. tower_tolerations:
  125. description: node tolerations for the AWX pods
  126. type: string
  127. tower_image:
  128. description: Registry path to the application container to use
  129. type: string
  130. tower_image_version:
  131. description: Application container image version to use
  132. type: string
  133. tower_ee_images:
  134. description: Registry path to the Execution Environment container to use
  135. type: array
  136. items:
  137. type: object
  138. properties:
  139. name:
  140. type: string
  141. image:
  142. type: string
  143. tower_image_pull_policy:
  144. description: The image pull policy
  145. type: string
  146. default: IfNotPresent
  147. enum:
  148. - Always
  149. - always
  150. - Never
  151. - never
  152. - IfNotPresent
  153. - ifnotpresent
  154. tower_image_pull_secret:
  155. description: The image pull secret
  156. type: string
  157. tower_task_resource_requirements:
  158. description: Resource requirements for the task container
  159. properties:
  160. requests:
  161. properties:
  162. cpu:
  163. type: string
  164. memory:
  165. type: string
  166. storage:
  167. type: string
  168. type: object
  169. limits:
  170. properties:
  171. cpu:
  172. type: string
  173. memory:
  174. type: string
  175. storage:
  176. type: string
  177. type: object
  178. type: object
  179. tower_web_resource_requirements:
  180. description: Resource requirements for the web container
  181. properties:
  182. requests:
  183. properties:
  184. cpu:
  185. type: string
  186. memory:
  187. type: string
  188. storage:
  189. type: string
  190. type: object
  191. limits:
  192. properties:
  193. cpu:
  194. type: string
  195. memory:
  196. type: string
  197. storage:
  198. type: string
  199. type: object
  200. type: object
  201. tower_replicas:
  202. description: Number of instance replicas
  203. type: integer
  204. default: 1
  205. format: int32
  206. tower_garbage_collect_secrets:
  207. description: Whether or not to remove secrets upon instance removal
  208. default: false
  209. type: boolean
  210. tower_create_preload_data:
  211. description: Whether or not to preload data upon Tower instance creation
  212. default: true
  213. type: boolean
  214. tower_task_args:
  215. type: array
  216. items:
  217. type: string
  218. tower_task_command:
  219. type: array
  220. items:
  221. type: string
  222. tower_web_args:
  223. type: array
  224. items:
  225. type: string
  226. tower_web_command:
  227. type: array
  228. items:
  229. type: string
  230. tower_task_extra_env:
  231. type: string
  232. tower_web_extra_env:
  233. type: string
  234. tower_ee_extra_volume_mounts:
  235. description: Specify volume mounts to be added to Execution container
  236. type: string
  237. tower_task_extra_volume_mounts:
  238. description: Specify volume mounts to be added to Task container
  239. type: string
  240. tower_web_extra_volume_mounts:
  241. description: Specify volume mounts to be added to the Web container
  242. type: string
  243. tower_redis_image:
  244. description: Registry path to the redis container to use
  245. type: string
  246. tower_redis_image_version:
  247. description: Redis container image version to use
  248. type: string
  249. tower_postgres_image:
  250. description: Registry path to the PostgreSQL container to use
  251. type: string
  252. tower_postgres_image_version:
  253. description: PostgreSQL container image version to use
  254. type: string
  255. tower_postgres_selector:
  256. description: nodeSelector for the Postgres pods
  257. type: string
  258. tower_postgres_tolerations:
  259. description: node tolerations for the Postgres pods
  260. type: string
  261. tower_postgres_storage_requirements:
  262. description: Storage requirements for the PostgreSQL container
  263. properties:
  264. requests:
  265. properties:
  266. storage:
  267. type: string
  268. type: object
  269. limits:
  270. properties:
  271. storage:
  272. type: string
  273. type: object
  274. type: object
  275. tower_postgres_resource_requirements:
  276. description: Resource requirements for the PostgreSQL container
  277. properties:
  278. requests:
  279. properties:
  280. cpu:
  281. type: string
  282. memory:
  283. type: string
  284. type: object
  285. limits:
  286. properties:
  287. cpu:
  288. type: string
  289. memory:
  290. type: string
  291. type: object
  292. type: object
  293. tower_postgres_storage_class:
  294. description: Storage class to use for the PostgreSQL PVC
  295. type: string
  296. tower_postgres_data_path:
  297. description: Path where the PostgreSQL data are located
  298. type: string
  299. ca_trust_bundle:
  300. description: Path where the trusted CA bundle is available
  301. type: string
  302. development_mode:
  303. description: If the deployment should be done in development mode
  304. type: boolean
  305. ldap_cacert_secret:
  306. description: Secret where can be found the LDAP trusted Certificate Authority Bundle
  307. type: string
  308. tower_projects_persistence:
  309. description: Whether or not the /var/lib/projects directory will be persistent
  310. default: false
  311. type: boolean
  312. tower_projects_use_existing_claim:
  313. description: Using existing PersistentVolumeClaim
  314. type: string
  315. enum:
  316. - _Yes_
  317. - _No_
  318. tower_projects_existing_claim:
  319. description: PersistentVolumeClaim to mount /var/lib/projects directory
  320. type: string
  321. tower_projects_storage_class:
  322. description: Storage class for the /var/lib/projects PersistentVolumeClaim
  323. type: string
  324. tower_projects_storage_size:
  325. description: Size for the /var/lib/projects PersistentVolumeClaim
  326. default: 8Gi
  327. type: string
  328. tower_projects_storage_access_mode:
  329. description: AccessMode for the /var/lib/projects PersistentVolumeClaim
  330. default: ReadWriteMany
  331. type: string
  332. extra_settings:
  333. description: Extra settings to specify for the API
  334. items:
  335. properties:
  336. setting:
  337. type: string
  338. value:
  339. type: string
  340. type: object
  341. type: array
  342. type: object
  343. status:
  344. properties:
  345. towerURL:
  346. description: URL to access the deployed instance
  347. type: string
  348. towerAdminUser:
  349. description: Admin user of the deployed instance
  350. type: string
  351. towerAdminPasswordSecret:
  352. description: Admin password of the deployed instance
  353. type: string
  354. towerMigratedFromSecret:
  355. description: The secret used for migrating an old Tower.
  356. type: string
  357. towerVersion:
  358. description: Version of the deployed instance
  359. type: string
  360. towerImage:
  361. description: URL of the image used for the deployed instance
  362. type: string
  363. conditions:
  364. description: The resulting conditions when a Service Telemetry is instantiated
  365. items:
  366. properties:
  367. status:
  368. type: string
  369. type:
  370. type: string
  371. reason:
  372. type: string
  373. lastTransitionTime:
  374. type: string
  375. type: object
  376. type: array
  377. type: object
  378. type: object
  379. ---
  380. apiVersion: rbac.authorization.k8s.io/v1
  381. kind: ClusterRole
  382. metadata:
  383. creationTimestamp: null
  384. name: awx-operator
  385. namespace: awx
  386. rules:
  387. - apiGroups:
  388. - route.openshift.io
  389. resources:
  390. - routes
  391. - routes/custom-host
  392. verbs:
  393. - '*'
  394. - apiGroups:
  395. - ""
  396. - "rbac.authorization.k8s.io"
  397. resources:
  398. - pods
  399. - services
  400. - services/finalizers
  401. - serviceaccounts
  402. - endpoints
  403. - persistentvolumeclaims
  404. - events
  405. - configmaps
  406. - secrets
  407. - roles
  408. - rolebindings
  409. verbs:
  410. - '*'
  411. - apiGroups:
  412. - apps
  413. - extensions
  414. resources:
  415. - deployments
  416. - daemonsets
  417. - replicasets
  418. - statefulsets
  419. - ingresses
  420. verbs:
  421. - '*'
  422. - apiGroups:
  423. - monitoring.coreos.com
  424. resources:
  425. - servicemonitors
  426. verbs:
  427. - get
  428. - create
  429. - apiGroups:
  430. - apps
  431. resourceNames:
  432. - awx-operator
  433. resources:
  434. - deployments/finalizers
  435. verbs:
  436. - update
  437. - apiGroups:
  438. - apps
  439. resources:
  440. - deployments/scale
  441. - statefulsets/scale
  442. verbs:
  443. - patch
  444. - apiGroups:
  445. - ""
  446. resources:
  447. - pods/exec
  448. verbs:
  449. - create
  450. - get
  451. - apiGroups:
  452. - apps
  453. resources:
  454. - replicasets
  455. verbs:
  456. - get
  457. - apiGroups:
  458. - awx.ansible.com
  459. resources:
  460. - '*'
  461. verbs:
  462. - '*'
  463. ---
  464. kind: ClusterRoleBinding
  465. apiVersion: rbac.authorization.k8s.io/v1
  466. metadata:
  467. name: awx-operator
  468. namespace: awx
  469. subjects:
  470. - kind: ServiceAccount
  471. name: awx-operator
  472. namespace: awx
  473. roleRef:
  474. kind: ClusterRole
  475. name: awx-operator
  476. apiGroup: rbac.authorization.k8s.io
  477. ---
  478. apiVersion: v1
  479. kind: ServiceAccount
  480. metadata:
  481. name: awx-operator
  482. namespace: awx
  483. ---
  484. apiVersion: apps/v1
  485. kind: Deployment
  486. metadata:
  487. name: awx-operator
  488. namespace: awx
  489. spec:
  490. replicas: 1
  491. selector:
  492. matchLabels:
  493. name: awx-operator
  494. template:
  495. metadata:
  496. labels:
  497. name: awx-operator
  498. spec:
  499. serviceAccountName: awx-operator
  500. containers:
  501. - name: awx-operator
  502. image: "quay.io/ansible/awx-operator:0.9.0"
  503. imagePullPolicy: "Always"
  504. volumeMounts:
  505. - mountPath: /tmp/ansible-operator/runner
  506. name: runner
  507. env:
  508. # Watch all namespaces (cluster-scoped).
  509. - name: WATCH_NAMESPACE
  510. value: ""
  511. - name: POD_NAME
  512. valueFrom:
  513. fieldRef:
  514. fieldPath: metadata.name
  515. - name: OPERATOR_NAME
  516. value: awx-operator
  517. - name: ANSIBLE_GATHERING
  518. value: explicit
  519. livenessProbe:
  520. httpGet:
  521. path: /healthz
  522. port: 6789
  523. initialDelaySeconds: 15
  524. periodSeconds: 20
  525. volumes:
  526. - name: runner
  527. emptyDir: {}