== helm chart 标准化 == - instances/standalones: 写死文件 → range 循环(加/删点位只改 values) - values 加 webName(显式前端名)+ description(Gateway 中文展示名) - _backend.tpl: Service 加 mixingx.io/description annotation + 补 ultra serviceId - _frontend.tpl/audit.yaml/mock.yaml: 注入 TZ env - values 加 timezone 变量(部署地域可覆盖,默认 Asia/Shanghai) - 修 app-ingress.yaml gatewayService/gatewayPort undefined bug - 验证: helm diff 资源数一致(61=61),加 agent-beijing 点位 8 资源全部正确生成 == 12 个 Dockerfile 加时区 == 后端(.NET debian): apt-get tzdata + ln /etc/localtime + ENV TZ 前端(nginx alpine): apk add tzdata audit(node alpine): apk add tzdata mock(opcua/s7): 同上 镜像内置 Asia/Shanghai 兜底 + helm TZ env 覆盖 = 双保险 == submodule Dockerfile 重写 == agent/edge/ultra: 重写适配 hub 根 context(含 ServiceDefaults 跨仓库引用) sso/gateway: 加时区 == submodule 指针更新 == 7 个 submodule 指针全部更新
19 lines
997 B
YAML
19 lines
997 B
YAML
{{/*
|
|
四胞胎实例(agent/edge)— 遍历 values.instances 数组
|
|
每个实例生成:后端 Deployment + 前端 Deployment + 独立 postgres StatefulSet(三者 podAffinity 同节点)
|
|
|
|
加/删点位:只改 values.yaml 的 instances 数组,helm upgrade 自动生效。
|
|
*/}}
|
|
{{- range $inst := .Values.instances }}
|
|
{{- $root := $ }}
|
|
# ═══ 实例: {{ $inst.name }} ({{ $inst.description }}) ═══
|
|
# 1. 后端
|
|
{{ include "mixingx.backend" (dict "name" $inst.name "image" $inst.image "role" $inst.role "serviceId" $inst.serviceId "database" $inst.database "description" $inst.description "root" $root) }}
|
|
|
|
# 2. 前端(亲和到后端同节点)
|
|
{{ include "mixingx.frontend" (dict "name" $inst.webName "image" $inst.webImage "basePath" $inst.webBasePath "affinity" $inst.name "root" $root) }}
|
|
|
|
# 3. 独立 postgres(亲和到后端同节点)
|
|
{{ include "mixingx.postgres" (dict "name" $inst.name "database" $inst.database "pgStorage" $inst.pgStorage "affinity" true "root" $root) }}
|
|
{{- end }}
|