logging-deployer.yaml 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302
  1. apiVersion: "v1"
  2. kind: "List"
  3. items:
  4. -
  5. apiVersion: "v1"
  6. kind: "Template"
  7. metadata:
  8. name: logging-deployer-account-template
  9. annotations:
  10. description: "Template for creating the deployer account and roles needed for the aggregated logging deployer. Create as cluster-admin."
  11. tags: "infrastructure"
  12. objects:
  13. - apiVersion: v1
  14. kind: ServiceAccount
  15. name: logging-deployer
  16. metadata:
  17. name: logging-deployer
  18. labels:
  19. logging-infra: deployer
  20. provider: openshift
  21. component: deployer
  22. secrets:
  23. - name: logging-deployer
  24. -
  25. apiVersion: v1
  26. kind: ServiceAccount
  27. metadata:
  28. name: aggregated-logging-kibana
  29. -
  30. apiVersion: v1
  31. kind: ServiceAccount
  32. metadata:
  33. name: aggregated-logging-elasticsearch
  34. -
  35. apiVersion: v1
  36. kind: ServiceAccount
  37. metadata:
  38. name: aggregated-logging-fluentd
  39. -
  40. apiVersion: v1
  41. kind: ServiceAccount
  42. metadata:
  43. name: aggregated-logging-curator
  44. - apiVersion: v1
  45. kind: ClusterRole
  46. metadata:
  47. name: oauth-editor
  48. rules:
  49. - resources:
  50. - oauthclients
  51. verbs:
  52. - create
  53. - delete
  54. - apiVersion: v1
  55. kind: ClusterRole
  56. metadata:
  57. name: daemonset-admin
  58. rules:
  59. - resources:
  60. - daemonsets
  61. apiGroups:
  62. - extensions
  63. verbs:
  64. - create
  65. - get
  66. - list
  67. - watch
  68. - delete
  69. - update
  70. -
  71. apiVersion: "v1"
  72. kind: "Template"
  73. metadata:
  74. name: logging-deployer-template
  75. annotations:
  76. description: "Template for running the aggregated logging deployer in a pod. Requires empowered 'logging-deployer' service account and 'logging-deployer' secret."
  77. tags: "infrastructure"
  78. labels:
  79. logging-infra: deployer
  80. provider: openshift
  81. component: deployer
  82. objects:
  83. -
  84. apiVersion: v1
  85. kind: Pod
  86. metadata:
  87. generateName: logging-deployer-
  88. spec:
  89. containers:
  90. - image: ${IMAGE_PREFIX}logging-deployment:${IMAGE_VERSION}
  91. imagePullPolicy: Always
  92. name: deployer
  93. volumeMounts:
  94. - name: secret
  95. mountPath: /secret
  96. readOnly: true
  97. - name: empty
  98. mountPath: /etc/deploy
  99. env:
  100. - name: PROJECT
  101. valueFrom:
  102. fieldRef:
  103. fieldPath: metadata.namespace
  104. - name: IMAGE_PREFIX
  105. value: ${IMAGE_PREFIX}
  106. - name: IMAGE_VERSION
  107. value: ${IMAGE_VERSION}
  108. - name: IMAGE_PULL_SECRET
  109. value: ${IMAGE_PULL_SECRET}
  110. - name: INSECURE_REGISTRY
  111. value: ${INSECURE_REGISTRY}
  112. - name: ENABLE_OPS_CLUSTER
  113. value: ${ENABLE_OPS_CLUSTER}
  114. - name: KIBANA_HOSTNAME
  115. value: ${KIBANA_HOSTNAME}
  116. - name: KIBANA_OPS_HOSTNAME
  117. value: ${KIBANA_OPS_HOSTNAME}
  118. - name: PUBLIC_MASTER_URL
  119. value: ${PUBLIC_MASTER_URL}
  120. - name: MASTER_URL
  121. value: ${MASTER_URL}
  122. - name: ES_INSTANCE_RAM
  123. value: ${ES_INSTANCE_RAM}
  124. - name: ES_PVC_SIZE
  125. value: ${ES_PVC_SIZE}
  126. - name: ES_PVC_PREFIX
  127. value: ${ES_PVC_PREFIX}
  128. - name: ES_CLUSTER_SIZE
  129. value: ${ES_CLUSTER_SIZE}
  130. - name: ES_NODE_QUORUM
  131. value: ${ES_NODE_QUORUM}
  132. - name: ES_RECOVER_AFTER_NODES
  133. value: ${ES_RECOVER_AFTER_NODES}
  134. - name: ES_RECOVER_EXPECTED_NODES
  135. value: ${ES_RECOVER_EXPECTED_NODES}
  136. - name: ES_RECOVER_AFTER_TIME
  137. value: ${ES_RECOVER_AFTER_TIME}
  138. - name: ES_OPS_INSTANCE_RAM
  139. value: ${ES_OPS_INSTANCE_RAM}
  140. - name: ES_OPS_PVC_SIZE
  141. value: ${ES_OPS_PVC_SIZE}
  142. - name: ES_OPS_PVC_PREFIX
  143. value: ${ES_OPS_PVC_PREFIX}
  144. - name: ES_OPS_CLUSTER_SIZE
  145. value: ${ES_OPS_CLUSTER_SIZE}
  146. - name: ES_OPS_NODE_QUORUM
  147. value: ${ES_OPS_NODE_QUORUM}
  148. - name: ES_OPS_RECOVER_AFTER_NODES
  149. value: ${ES_OPS_RECOVER_AFTER_NODES}
  150. - name: ES_OPS_RECOVER_EXPECTED_NODES
  151. value: ${ES_OPS_RECOVER_EXPECTED_NODES}
  152. - name: ES_OPS_RECOVER_AFTER_TIME
  153. value: ${ES_OPS_RECOVER_AFTER_TIME}
  154. - name: FLUENTD_NODESELECTOR
  155. value: ${FLUENTD_NODESELECTOR}
  156. - name: ES_NODESELECTOR
  157. value: ${ES_NODESELECTOR}
  158. - name: ES_OPS_NODESELECTOR
  159. value: ${ES_OPS_NODESELECTOR}
  160. - name: KIBANA_NODESELECTOR
  161. value: ${KIBANA_NODESELECTOR}
  162. - name: KIBANA_OPS_NODESELECTOR
  163. value: ${KIBANA_OPS_NODESELECTOR}
  164. - name: CURATOR_NODESELECTOR
  165. value: ${CURATOR_NODESELECTOR}
  166. - name: CURATOR_OPS_NODESELECTOR
  167. value: ${CURATOR_OPS_NODESELECTOR}
  168. - name: MODE
  169. value: ${MODE}
  170. dnsPolicy: ClusterFirst
  171. restartPolicy: Never
  172. serviceAccount: logging-deployer
  173. volumes:
  174. - name: empty
  175. emptyDir: {}
  176. - name: secret
  177. secret:
  178. secretName: logging-deployer
  179. parameters:
  180. -
  181. description: "If true, set up to use a second ES cluster for ops logs."
  182. name: ENABLE_OPS_CLUSTER
  183. value: "false"
  184. -
  185. description: "External hostname where clients will reach kibana"
  186. name: KIBANA_HOSTNAME
  187. required: true
  188. -
  189. description: "External hostname at which admins will visit the ops Kibana."
  190. name: KIBANA_OPS_HOSTNAME
  191. value: kibana-ops.example.com
  192. -
  193. description: "External URL for the master, for OAuth purposes"
  194. name: PUBLIC_MASTER_URL
  195. required: true
  196. -
  197. description: "Internal URL for the master, for authentication retrieval"
  198. name: MASTER_URL
  199. value: "https://kubernetes.default.svc.cluster.local"
  200. -
  201. description: "How many instances of ElasticSearch to deploy."
  202. name: ES_CLUSTER_SIZE
  203. required: true
  204. -
  205. description: "Amount of RAM to reserve per ElasticSearch instance."
  206. name: ES_INSTANCE_RAM
  207. value: "8G"
  208. -
  209. description: "Size of the PersistentVolumeClaim to create per ElasticSearch instance, e.g. 100G. If empty, no PVCs will be created and emptyDir volumes are used instead."
  210. name: ES_PVC_SIZE
  211. -
  212. description: "Prefix for the names of PersistentVolumeClaims to be created; a number will be appended per instance. If they don't already exist, they will be created with size ES_PVC_SIZE."
  213. name: ES_PVC_PREFIX
  214. value: "logging-es-"
  215. -
  216. description: "Number of nodes required to elect a master (ES minimum_master_nodes). By default, derived from ES_CLUSTER_SIZE / 2 + 1."
  217. name: ES_NODE_QUORUM
  218. -
  219. description: "Number of nodes required to be present before the cluster will recover from a full restart. By default, one fewer than ES_CLUSTER_SIZE."
  220. name: ES_RECOVER_AFTER_NODES
  221. -
  222. description: "Number of nodes desired to be present before the cluster will recover from a full restart. By default, ES_CLUSTER_SIZE."
  223. name: ES_RECOVER_EXPECTED_NODES
  224. -
  225. description: "Timeout for *expected* nodes to be present when cluster is recovering from a full restart."
  226. name: ES_RECOVER_AFTER_TIME
  227. value: "5m"
  228. -
  229. description: "How many ops instances of ElasticSearch to deploy. By default, ES_CLUSTER_SIZE."
  230. name: ES_OPS_CLUSTER_SIZE
  231. -
  232. description: "Amount of RAM to reserve per ops ElasticSearch instance."
  233. name: ES_OPS_INSTANCE_RAM
  234. value: "8G"
  235. -
  236. description: "Size of the PersistentVolumeClaim to create per ElasticSearch ops instance, e.g. 100G. If empty, no PVCs will be created and emptyDir volumes are used instead."
  237. name: ES_OPS_PVC_SIZE
  238. -
  239. description: "Prefix for the names of PersistentVolumeClaims to be created; a number will be appended per instance. If they don't already exist, they will be created with size ES_OPS_PVC_SIZE."
  240. name: ES_OPS_PVC_PREFIX
  241. value: "logging-es-ops-"
  242. -
  243. description: "Number of ops nodes required to elect a master (ES minimum_master_nodes). By default, derived from ES_CLUSTER_SIZE / 2 + 1."
  244. name: ES_OPS_NODE_QUORUM
  245. -
  246. description: "Number of ops nodes required to be present before the cluster will recover from a full restart. By default, one fewer than ES_OPS_CLUSTER_SIZE."
  247. name: ES_OPS_RECOVER_AFTER_NODES
  248. -
  249. description: "Number of ops nodes desired to be present before the cluster will recover from a full restart. By default, ES_OPS_CLUSTER_SIZE."
  250. name: ES_OPS_RECOVER_EXPECTED_NODES
  251. -
  252. description: "Timeout for *expected* ops nodes to be present when cluster is recovering from a full restart."
  253. name: ES_OPS_RECOVER_AFTER_TIME
  254. value: "5m"
  255. -
  256. description: "The nodeSelector used for the Fluentd DaemonSet."
  257. name: FLUENTD_NODESELECTOR
  258. value: "logging-infra-fluentd=true"
  259. -
  260. description: "Node selector Elasticsearch cluster (label=value)."
  261. name: ES_NODESELECTOR
  262. value: ""
  263. -
  264. description: "Node selector Elasticsearch operations cluster (label=value)."
  265. name: ES_OPS_NODESELECTOR
  266. value: ""
  267. -
  268. description: "Node selector Kibana cluster (label=value)."
  269. name: KIBANA_NODESELECTOR
  270. value: ""
  271. -
  272. description: "Node selector Kibana operations cluster (label=value)."
  273. name: KIBANA_OPS_NODESELECTOR
  274. value: ""
  275. -
  276. description: "Node selector Curator (label=value)."
  277. name: CURATOR_NODESELECTOR
  278. value: ""
  279. -
  280. description: "Node selector operations Curator (label=value)."
  281. name: CURATOR_OPS_NODESELECTOR
  282. value: ""
  283. -
  284. description: "The mode that the deployer runs in."
  285. name: MODE
  286. value: "install"
  287. -
  288. description: 'Specify prefix for logging components; e.g. for "openshift/origin-logging-deployer:v1.1", set prefix "openshift/origin-"'
  289. name: IMAGE_PREFIX
  290. value: "docker.io/openshift/origin-"
  291. -
  292. description: 'Specify version for logging components; e.g. for "openshift/origin-logging-deployer:v1.1", set version "v1.1"'
  293. name: IMAGE_VERSION
  294. value: "latest"
  295. -
  296. description: 'Specify the name of an existing pull secret to be used for pulling component images from an authenticated registry.'
  297. name: IMAGE_PULL_SECRET
  298. -
  299. description: 'Allow the registry for logging component images to be non-secure (not secured with a certificate signed by a known CA)'
  300. name: INSECURE_REGISTRY
  301. value: "false"