cloudwise-euspace-ds.yaml 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. apiVersion: apps/v1
  2. kind: DaemonSet
  3. metadata:
  4. name: cloudwise-apm-euspace
  5. namespace: cloudwise
  6. spec:
  7. selector:
  8. matchLabels:
  9. app: cloudwise-apm-euspace
  10. template:
  11. metadata:
  12. annotations:
  13. container.apparmor.security.beta.kubernetes.io/cloudwise-apm-euspace: unconfined
  14. name: cloudwise-apm-euspace
  15. namespace: cloudwise
  16. labels:
  17. app: cloudwise-apm-euspace
  18. spec:
  19. hostPID: true
  20. hostNetwork: true
  21. nodeSelector:
  22. kubernetes.io/os: linux
  23. kubernetes.io/arch: amd64
  24. containers:
  25. - name: cloudwise-apm-euspace
  26. image: harbor.cloudwise.com/apm/euspace-agent:1.6.1-dev-amd64
  27. imagePullPolicy: IfNotPresent
  28. args: ["--listen", "0.0.0.0:8123", "--cgroupfs-root", "/host/sys/fs/cgroup","--run-in-container"]
  29. ports:
  30. - containerPort: 8123
  31. name: http
  32. securityContext:
  33. privileged: true
  34. runAsUser: 0
  35. volumeMounts:
  36. - name: sys-fs-cgroup
  37. mountPath: /host/sys/fs/cgroup
  38. readOnly: true
  39. - name: sys-kernel-debug
  40. mountPath: /sys/kernel/debug
  41. readOnly: true
  42. - name: host-usr
  43. mountPath: /host/usr
  44. readOnly: true
  45. mountPropagation: HostToContainer
  46. - name: host-var
  47. mountPath: /host/var
  48. readOnly: false
  49. mountPropagation: HostToContainer
  50. - name: host-run
  51. mountPath: /host/run
  52. readOnly: false
  53. mountPropagation: HostToContainer
  54. - name: host-tmp
  55. mountPath: /host/tmp
  56. readOnly: false
  57. mountPropagation: HostToContainer
  58. env:
  59. - name: CONFIG_SERVER
  60. value: ''
  61. - name: DATA_SERVER
  62. value: ''
  63. - name: LICENSE_KEY
  64. value: 'J45Engw88NeHUZ4Q7qNsK8L47FTH**QvgW113IEnsNaBNMR5zZ**oj/g!!!!'
  65. - name: MYSQL_DEFAULT
  66. value: 'mariadb'
  67. - name: DISABLE_E2E_TRACING
  68. value: 'false'
  69. - name: DISABLE_STACK_TRACING
  70. value: 'true'
  71. - name: DISABLE_REG_HOST
  72. value: 'false'
  73. - name: CONSOLE_LOG
  74. value: 'true'
  75. - name: LOG_LEVEL
  76. value: 'info'
  77. - name: SEND
  78. value: '1'
  79. - name: INSECURE_SKIP_VERIFY
  80. value: 'true'
  81. - name: node_ip
  82. valueFrom:
  83. fieldRef:
  84. fieldPath: status.hostIP
  85. - name: REGISTER_APP_TO_DOOP
  86. value: 'true'
  87. volumes:
  88. - name: sys-fs-cgroup
  89. hostPath:
  90. path: /sys/fs/cgroup
  91. - name: sys-kernel-debug
  92. hostPath:
  93. path: /sys/kernel/debug
  94. - name: host-usr
  95. hostPath:
  96. path: /usr
  97. type: Directory
  98. - name: host-var
  99. hostPath:
  100. path: /var
  101. type: Directory
  102. - name: host-run
  103. hostPath:
  104. path: /run
  105. type: Directory
  106. - name: host-tmp
  107. hostPath:
  108. path: /tmp
  109. type: Directory
  110. ---
  111. kind: ClusterRole
  112. apiVersion: rbac.authorization.k8s.io/v1
  113. metadata:
  114. name: euspace-agent-role
  115. rules:
  116. - apiGroups: [""]
  117. resources:
  118. - nodes
  119. - namespaces
  120. - configmaps
  121. - services
  122. - pods
  123. - replicationcontrollers
  124. verbs: ["get", "list", "watch"]
  125. - apiGroups: ["apps"]
  126. resources:
  127. - daemonsets
  128. - deployments
  129. - replicasets
  130. - statefulsets
  131. verbs: ["get", "list", "watch"]
  132. - apiGroups: ["extensions", "networking.k8s.io"]
  133. resources: ["ingresses"]
  134. verbs: ["get", "list", "watch"]
  135. - apiGroups: ["route.openshift.io"]
  136. resources: ["routes"]
  137. verbs: ["get", "list", "watch"]
  138. ---
  139. apiVersion: rbac.authorization.k8s.io/v1
  140. kind: ClusterRoleBinding
  141. metadata:
  142. name: cw-agent-view-binding
  143. subjects:
  144. - kind: ServiceAccount
  145. name: default
  146. namespace: cloudwise
  147. roleRef:
  148. kind: ClusterRole
  149. name: euspace-agent-role
  150. apiGroup: rbac.authorization.k8s.io