values.yaml 9.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261
  1. # Default values for chart.
  2. # This is a YAML-formatted file.
  3. # Declare variables to be passed into your templates.
  4. # This is for the secrets for pulling an image from a private repository more information can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
  5. # ECR pulls are authenticated via the node IAM role (or IRSA on the service account),
  6. # so no imagePullSecrets entry is required for the ECR repositories below.
  7. imagePullSecrets: []
  8. # This is to override the chart name.
  9. nameOverride: ""
  10. fullnameOverride: ""
  11. # This section builds out the service account more information can be found here: https://kubernetes.io/docs/concepts/security/service-accounts/
  12. serviceAccount:
  13. # Specifies whether a service account should be created.
  14. create: true
  15. # Automatically mount a ServiceAccount's API credentials?
  16. automount: true
  17. # Annotations to add to the service account.
  18. annotations: {}
  19. # The name of the service account to use.
  20. # If not set and create is true, a name is generated using the fullname template.
  21. name: ""
  22. # Pod-level security context shared by every component (component-level overrides win).
  23. podSecurityContext:
  24. runAsNonRoot: true
  25. seccompProfile:
  26. type: RuntimeDefault
  27. # Container-level security context shared by every component (component-level overrides win).
  28. securityContext:
  29. allowPrivilegeEscalation: false
  30. capabilities:
  31. drop:
  32. - ALL
  33. # RDS endpoint host:port consumed by the backend Secret below.
  34. # Replace `aex.<...>.rds.amazonaws.com` with the actual RDS writer endpoint.
  35. rds:
  36. host: skinc-aiagent-dev-main-postgresql.cn8yeeaaa1s1.ap-northeast-2.rds.amazonaws.com
  37. port: 5432
  38. database: aiagtmpn_dev
  39. # Components served by this chart. Each entry produces its own Deployment, Service, and (optional) HPA.
  40. # The Ingress below references components by key (e.g. `frontend`, `backend`).
  41. components:
  42. # Frontend (aex_ft) — serves all traffic that does not match /api.
  43. frontend:
  44. # This will set the replicaset count more information can be found here: https://kubernetes.io/docs/concepts/workloads/controllers/replicaset/
  45. replicaCount: 1
  46. # This sets the container image more information can be found here: https://kubernetes.io/docs/concepts/containers/images/
  47. image:
  48. repository: 406005162200.dkr.ecr.ap-northeast-2.amazonaws.com/aex/ft
  49. # This sets the pull policy for images.
  50. pullPolicy: IfNotPresent
  51. # Overrides the image tag whose default is the chart appVersion.
  52. tag: "0.0.0c"
  53. # nginx in the frontend image listens on 8080 (see sk_private_front/docker/nginx.conf).
  54. # Service exposes port 80 and targets the named container port `http` → 8080.
  55. containerPort: 8080
  56. # This is for setting Kubernetes Annotations to a Pod.
  57. podAnnotations: {}
  58. # This is for setting Kubernetes Labels to a Pod.
  59. podLabels: {}
  60. # This is for setting up a service more information can be found here: https://kubernetes.io/docs/concepts/services-networking/service/
  61. service:
  62. type: ClusterIP
  63. port: 80
  64. # readOnlyRootFilesystem requires writable mounts for nginx cache and pid file.
  65. securityContext:
  66. allowPrivilegeEscalation: false
  67. capabilities:
  68. drop:
  69. - ALL
  70. readOnlyRootFilesystem: true
  71. runAsNonRoot: true
  72. runAsUser: 101
  73. runAsGroup: 101
  74. # This is to setup the liveness and readiness probes more information can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/
  75. livenessProbe:
  76. httpGet:
  77. path: /
  78. port: http
  79. readinessProbe:
  80. httpGet:
  81. path: /
  82. port: http
  83. # Minimal requests so the scheduler can place the pod; no limits to keep the test deploy permissive.
  84. resources:
  85. requests:
  86. cpu: 50m
  87. memory: 64Mi
  88. # This section is for setting up autoscaling more information can be found here: https://kubernetes.io/docs/concepts/workloads/autoscaling/
  89. autoscaling:
  90. enabled: false
  91. minReplicas: 1
  92. maxReplicas: 100
  93. targetCPUUtilizationPercentage: 80
  94. # targetMemoryUtilizationPercentage: 80
  95. # Writable scratch dirs required because the rootfs is read-only.
  96. # /run is needed because the upstream nginx.conf writes its pid file there
  97. # (the Dockerfile's sed targets /var/run/... and misses the actual /run/...).
  98. volumes:
  99. - name: nginx-cache
  100. emptyDir: {}
  101. - name: nginx-tmp
  102. emptyDir: {}
  103. - name: nginx-run
  104. emptyDir: {}
  105. volumeMounts:
  106. - name: nginx-cache
  107. mountPath: /var/cache/nginx
  108. - name: nginx-tmp
  109. mountPath: /tmp
  110. - name: nginx-run
  111. mountPath: /run
  112. # Backend (aex_bn) — serves traffic under /api.
  113. backend:
  114. replicaCount: 1
  115. image:
  116. repository: 406005162200.dkr.ecr.ap-northeast-2.amazonaws.com/aex/bn
  117. pullPolicy: IfNotPresent
  118. tag: "0.0.0c"
  119. containerPort: 8000
  120. podAnnotations: {}
  121. podLabels: {}
  122. service:
  123. type: ClusterIP
  124. port: 8000
  125. # uvicorn user `app` is uid/gid 1000 in sk_private/docker/dockerfile.
  126. securityContext:
  127. allowPrivilegeEscalation: false
  128. capabilities:
  129. drop:
  130. - ALL
  131. readOnlyRootFilesystem: true
  132. runAsNonRoot: true
  133. runAsUser: 1000
  134. runAsGroup: 1000
  135. livenessProbe:
  136. httpGet:
  137. path: /health
  138. port: http
  139. readinessProbe:
  140. httpGet:
  141. path: /health
  142. port: http
  143. resources:
  144. requests:
  145. cpu: 100m
  146. memory: 256Mi
  147. autoscaling:
  148. enabled: false
  149. minReplicas: 1
  150. maxReplicas: 100
  151. targetCPUUtilizationPercentage: 80
  152. # /tmp scratch for read-only rootfs (Python may write caches/temp files).
  153. volumes:
  154. - name: tmp
  155. emptyDir: {}
  156. volumeMounts:
  157. - name: tmp
  158. mountPath: /tmp
  159. # Pull configuration from the Secret rendered below.
  160. envFrom:
  161. - secretRef:
  162. name: '{{ include "chart.componentFullname" (dict "root" $ "name" "backend") }}'
  163. - configMapRef:
  164. name: '{{ include "chart.componentFullname" (dict "root" $ "name" "backend") }}-config'
  165. # Secret consumed by the backend; rendered as <release>-<chart>-backend.
  166. configMap:
  167. data:
  168. APP_LOG_LEVEL: DEBUG
  169. # APP_DATABASE_URL points at the AWS RDS endpoint configured under .Values.rds.
  170. secret:
  171. stringData:
  172. APP_DATABASE_URL: 'postgresql+asyncpg://aex_dev:qct6mjpiqo@{{ $.Values.rds.host }}:{{ $.Values.rds.port }}/{{ $.Values.rds.database }}'
  173. APP_DATABASE_SCHEMA: aex_sch
  174. # This block is for setting up the ingress for more information can be found here: https://kubernetes.io/docs/concepts/services-networking/ingress/
  175. # AWS Load Balancer Controller provisions an ALB from this resource.
  176. ingressBackend:
  177. enabled: true
  178. className: alb-custom
  179. annotations:
  180. # alb.ingress.kubernetes.io/scheme: internet-facing
  181. alb.ingress.kubernetes.io/group.name: "appl"
  182. alb.ingress.kubernetes.io/load-balancer-name: skinc-inc-lb-dev-test-2
  183. alb.ingress.kubernetes.io/target-type: "ip"
  184. alb.ingress.kubernetes.io/listen-ports: '[{"HTTP":80},{"HTTPS":443}]'
  185. alb.ingress.kubernetes.io/healthcheck-protocol: HTTP
  186. alb.ingress.kubernetes.io/healthcheck-path: /health
  187. alb.ingress.kubernetes.io/healthcheck-port: "8000"
  188. hosts:
  189. # host를 비우면 ALB가 모든 Host 헤더에 대해 매칭 → ALB DNS로 직접 접속 가능.
  190. # 운영 단계에서는 실제 도메인(예: aex.example.com)을 넣고 Route53 ALIAS 등록 권장.
  191. - host: "aex.dev.skinc.co.kr"
  192. paths:
  193. - path: /api
  194. pathType: Prefix
  195. component: backend
  196. tls: []
  197. # - secretName: chart-example-tls
  198. # hosts:
  199. # - chart-example.local
  200. ingressFrontend:
  201. enabled: true
  202. className: alb-custom
  203. annotations:
  204. # alb.ingress.kubernetes.io/scheme: internet-facing
  205. alb.ingress.kubernetes.io/group.name: "appl"
  206. alb.ingress.kubernetes.io/load-balancer-name: skinc-inc-lb-dev-test-2
  207. alb.ingress.kubernetes.io/target-type: "ip"
  208. alb.ingress.kubernetes.io/listen-ports: '[{"HTTP":80},{"HTTPS":443}]'
  209. alb.ingress.kubernetes.io/healthcheck-protocol: HTTP
  210. alb.ingress.kubernetes.io/healthcheck-path: /
  211. alb.ingress.kubernetes.io/healthcheck-port: "80"
  212. hosts:
  213. # host를 비우면 ALB가 모든 Host 헤더에 대해 매칭 → ALB DNS로 직접 접속 가능.
  214. # 운영 단계에서는 실제 도메인(예: aex.example.com)을 넣고 Route53 ALIAS 등록 권장.
  215. - host: "aex.dev.skinc.co.kr"
  216. paths:
  217. - path: /
  218. pathType: Prefix
  219. component: frontend
  220. tls: []
  221. # - secretName: chart-example-tls
  222. # hosts:
  223. # - chart-example.local
  224. # -- Expose the services via gateway-api HTTPRoute
  225. # Disabled — routing is handled by the ALB Ingress above.
  226. httpRoute:
  227. enabled: false
  228. annotations: {}
  229. parentRefs:
  230. - name: gateway
  231. sectionName: http
  232. hostnames:
  233. - aex.sk-inc.local
  234. rules:
  235. - matches:
  236. - path:
  237. type: PathPrefix
  238. value: /api
  239. backendRefs:
  240. - component: backend
  241. - matches:
  242. - path:
  243. type: PathPrefix
  244. value: /
  245. backendRefs:
  246. - component: frontend
  247. nodeSelector: {}
  248. tolerations: []
  249. affinity: {}