Compare commits

..
Author SHA1 Message Date
薛佳帆 0afaa17112 release: bump chart version to v1.0.98 2026-11-11 16:40:05 +08:00
薛佳帆 bf0170aa26 fix(dotnet): 全部 .NET 主容器加 appArmorProfile Unconfined——AppArmor 拒线程定向信号致 GC abort
根因(dotnet/runtime#136603,已由同事在 sciveda 现场实测验证):Ubuntu 26.04 新内核
配套 AppArmor 行为禁止容器内进程向自身线程发信号(pthread_kill/tgkill → EACCES),
CoreCLR GC 挂起线程失败 → 运行时 abort → dmesg 表现为 'general protection fault
in libc.so.6[+0x289a2]'(.NET BGC/Server GC/TP Worker 线程),容器 exit 139
CrashLoop,负载越高崩得越频,且 journalctl 无 apparmor=DENIED 记录。
同机制亦解释此前 postgres 'could not signal for checkpoint: Permission denied'
(privileged 之所以有效 = privileged 容器不受 AppArmor 约束)。
修复:agent/sso/ultra/edge/gateway/platform 六处 .NET 主容器
securityContext.appArmorProfile.type: Unconfined。
2026-11-11 16:38:24 +08:00
drone dcc948188b release: bump chart version to v1.0.97 2026-11-10 08:26:38 +00:00
drone 78b9b9db15 release: bump chart version to v1.0.96 2026-11-10 08:24:27 +00:00
薛佳帆 2df3373304 release: bump chart version to v1.0.95 2026-11-10 16:23:26 +08:00
薛佳帆 9b002c6491 fix(postgres): 全部 postgres StatefulSet 三件套修复——绕过镜像内 gosu 直跑 + 特权容器
根因:官方 postgres:17 镜像(2026-08 构建)内 gosu 在新内核(Ubuntu 26.04 kernel 7.0.0-39+)上
用户态死循环,容器假活(Running 但 5432 无服务、PGDATA 空、零日志);绕过 gosu 后 PG17 恢复期
signal checkpoint 再遇权限死循环,故三件缺一不可:
- pod securityContext: runAsUser/runAsGroup/fsGroup=999(以 postgres 用户直跑,跳过 gosu)
- container command: docker-entrypoint.sh postgres(非 root 下 entrypoint 自动跳过 gosu)
- container securityContext: privileged(否则恢复期 'could not signal for checkpoint: Permission denied')

涉及 5 个模板:sso/ultra/audit(audit-db)/platform(audit)/agent-unit 各自内嵌的 postgres。
同内容已提交 develop 分支 407aef8;实测:xjf1641(Xeon+kernel43)与 wytest(i5+kernel42)
原始定义必死、打补丁后稳定;kernel 7.0.0-38 老机暂未触发但不免疫,升级内核前必须先吃本修复。
2026-11-10 16:21:57 +08:00
drone 6df5affe17 release: bump chart version to v1.0.94 2026-11-10 07:58:36 +00:00
drone bf915935ea release: bump chart version to v1.0.93 2026-11-10 07:42:51 +00:00
drone 6734c2022b release: bump chart version to v1.0.92 2026-11-10 07:05:56 +00:00
21 changed files with 82 additions and 143 deletions

No files matched your search

-16
View File
@@ -35,22 +35,6 @@ helm template ci-edge release-charts/mixingx-edge-unit
`mixingx-deploy` 的 ApplicationSet 按 unit chart 逐个发布,每个 edge/agent 一个独立 Helm release。详见 `mixingx-deploy/`。
## PostgreSQL on K3s
PostgreSQL StatefulSets use the Debian image's UID/GID 999 and run the image
entrypoint directly. This skips gosu while preserving database initialization
and startup on the existing data volume. The readiness probe uses
`pg_isready` over TCP so the container is Ready only after PostgreSQL accepts
connections, including after recovery.
Only the PostgreSQL container uses `privileged: true` as a temporary workaround
for checkpoint signal failures observed on affected Ubuntu 26.04 / K3s nodes.
The namespace's admission policy must permit privileged containers. The
[containerd signal-denial report](https://github.com/containerd/containerd/issues/14485)
describes the same checkpoint error with AppArmor. Check the host kernel log
for an AppArmor signal denial and validate initialization and recovery with the
corrected runtime or profile before removing privileged mode.
## 关联文档
- hub [AGENTS.md](https://gitee.com/mixing-tech/mixingx.hub) — 全项目指南
+2 -2
View File
@@ -2,5 +2,5 @@ apiVersion: v2
name: mixingx-agent-unit
description: "One MixingX agent unit release: agent backend, agent web, and agent PostgreSQL."
type: application
version: 1.0.91
appVersion: "1.0.91"
version: 1.0.98
appVersion: "1.0.98"
@@ -38,6 +38,9 @@ spec:
{{ $backendTag := $agentImg.tag | default $backendImg.tag | default .Values.tag | default "latest" }}
image: {{ .Values.registry }}/{{ $backendRepo }}:{{ $backendTag }}
imagePullPolicy: IfNotPresent
securityContext:
appArmorProfile:
type: Unconfined
ports:
- name: http
containerPort: {{ .Values.ports.backend }}
@@ -207,24 +210,24 @@ spec:
labels:
app.kubernetes.io/component: {{ $name }}-postgres
spec:
securityContext:
# Run the image entrypoint as postgres so it does not invoke gosu.
runAsUser: 999
runAsGroup: 999
fsGroup: 999
{{ include "mixingx-unit.followerScheduling" . | nindent 6 }}
{{- with $.Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
# postgres 以专用用户直跑,绕过镜像内 gosu(新内核下 gosu 用户态死循环,
# 见工单:kernel 7.0.0-39+ × gosu 兼容 bug;三件套缺一不可)
securityContext:
runAsUser: 999
runAsGroup: 999
fsGroup: 999
containers:
- name: postgres
image: {{ .Values.images.postgres.repository }}:{{ .Values.images.postgres.tag | default "latest" }}
imagePullPolicy: IfNotPresent
command: ["docker-entrypoint.sh", "postgres"]
securityContext:
# Temporary compatibility workaround for checkpoint signal failures on affected k3s nodes.
privileged: true
image: {{ .Values.images.postgres.repository }}:{{ .Values.images.postgres.tag | default "latest" }}
imagePullPolicy: IfNotPresent
env:
- name: POSTGRES_PASSWORD
value: "{{ .Values.sharedInfra.postgres.password }}"
@@ -238,15 +241,6 @@ spec:
- name: tcp
containerPort: {{ .Values.ports.postgres }}
protocol: TCP
readinessProbe:
exec:
command:
- sh
- -ec
- >-
exec pg_isready -q -h 127.0.0.1 -p {{ .Values.ports.postgres }} -U "$POSTGRES_USER" -d "$POSTGRES_DB"
periodSeconds: 5
timeoutSeconds: 3
volumeMounts:
- name: data
mountPath: /var/lib/postgresql/data
+2 -2
View File
@@ -2,5 +2,5 @@ apiVersion: v2
name: mixingx-audit
description: MixingX audit service.
type: application
version: 1.0.91
appVersion: "1.0.91"
version: 1.0.98
appVersion: "1.0.98"
@@ -31,24 +31,24 @@ spec:
labels:
app.kubernetes.io/component: {{ .Values.audit.database }}-postgres
spec:
securityContext:
# Run the image entrypoint as postgres so it does not invoke gosu.
runAsUser: 999
runAsGroup: 999
fsGroup: 999
{{ include "mixingx-audit.tierAffinity" (dict "role" "audit" "root" $root) | nindent 6 }}
{{- with $.Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
# postgres 以专用用户直跑,绕过镜像内 gosu(新内核下 gosu 用户态死循环,
# 见工单:kernel 7.0.0-39+ × gosu 兼容 bug;三件套缺一不可)
securityContext:
runAsUser: 999
runAsGroup: 999
fsGroup: 999
containers:
- name: postgres
image: {{ $root.Values.sharedInfra.postgres.image | default "docker.io/library/postgres:17" }}
imagePullPolicy: IfNotPresent
command: ["docker-entrypoint.sh", "postgres"]
securityContext:
# Temporary compatibility workaround for checkpoint signal failures on affected k3s nodes.
privileged: true
image: {{ $root.Values.sharedInfra.postgres.image | default "docker.io/library/postgres:17" }}
imagePullPolicy: IfNotPresent
env:
- name: POSTGRES_PASSWORD
value: "{{ $root.Values.sharedInfra.postgres.password }}"
@@ -62,15 +62,6 @@ spec:
- name: tcp
containerPort: {{ $root.Values.sharedInfra.postgres.port }}
protocol: TCP
readinessProbe:
exec:
command:
- sh
- -ec
- >-
exec pg_isready -q -h 127.0.0.1 -p {{ $root.Values.sharedInfra.postgres.port }} -U "$POSTGRES_USER" -d "$POSTGRES_DB"
periodSeconds: 5
timeoutSeconds: 3
volumeMounts:
- name: data
mountPath: /var/lib/postgresql/data
+2 -2
View File
@@ -2,5 +2,5 @@ apiVersion: v2
name: mixingx-codeserver
description: MixingX code-server — 浏览器版 VS Code 测试 IDE,预装 GitLens/EditorConfig/Prettier/C#/OPC UA Browser 插件。
type: application
version: 1.0.91
appVersion: "1.0.91"
version: 1.0.98
appVersion: "1.0.98"
+2 -2
View File
@@ -2,5 +2,5 @@ apiVersion: v2
name: mixingx-edge-unit
description: "One MixingX edge unit release with durable local revision storage."
type: application
version: 1.0.91
appVersion: "1.0.91"
version: 1.0.98
appVersion: "1.0.98"
@@ -71,6 +71,9 @@ spec:
{{ $backendTag := $edgeImg.tag | default $backendImg.tag | default .Values.tag | default "latest" }}
image: {{ .Values.registry }}/{{ $backendRepo }}:{{ $backendTag }}
imagePullPolicy: IfNotPresent
securityContext:
appArmorProfile:
type: Unconfined
ports:
- name: http
containerPort: {{ .Values.ports.backend }}
+2 -2
View File
@@ -2,5 +2,5 @@ apiVersion: v2
name: mixingx-gateway
description: MixingX gateway service, RBAC, and root ingress.
type: application
version: 1.0.91
appVersion: "1.0.91"
version: 1.0.98
appVersion: "1.0.98"
@@ -34,6 +34,9 @@ spec:
- name: gateway
image: {{ .Values.registry }}/{{ $gatewayImage.repository | default "gateway" }}:{{ $gatewayImage.tag | default .Values.tag | default "latest" }}
imagePullPolicy: IfNotPresent
securityContext:
appArmorProfile:
type: Unconfined
ports:
- name: http
containerPort: {{ .Values.gateway.port | default 8080 }}
+2 -2
View File
@@ -2,5 +2,5 @@ apiVersion: v2
name: mixingx-infra
description: MixingX shared infrastructure services (Redis, MongoDB, RabbitMQ).
type: application
version: 1.0.91
appVersion: "1.0.91"
version: 1.0.98
appVersion: "1.0.98"
+2 -2
View File
@@ -2,5 +2,5 @@ apiVersion: v2
name: mixingx-mqttx
description: MixingX MQTTX Web — 浏览器端 MQTT 客户端,用于监控/调试各 Edge 的 NanoMQ broker。
type: application
version: 1.0.91
appVersion: "1.0.91"
version: 1.0.98
appVersion: "1.0.98"
@@ -2,5 +2,5 @@ apiVersion: v2
name: mixingx-network-agent
description: "MixingX network console agent: 每节点常驻,提供主机网口(IP/掩码/网关/DNS)与 WiFi 的可视化配置 API。"
type: application
version: 1.0.91
appVersion: "1.0.91"
version: 1.0.98
appVersion: "1.0.98"
+2 -2
View File
@@ -2,5 +2,5 @@ apiVersion: v2
name: mixingx-platform
description: MixingX central platform services without customer edge/agent instances.
type: application
version: 1.0.91
appVersion: "1.0.91"
version: 1.0.98
appVersion: "1.0.98"
@@ -33,6 +33,9 @@ spec:
- name: {{ .name }}
image: {{ $root.Values.registry }}/{{ .image }}:{{ $root.Values.tag | default "latest" }}
imagePullPolicy: IfNotPresent
securityContext:
appArmorProfile:
type: Unconfined
ports:
- name: http
containerPort: {{ $port }}
@@ -231,11 +234,6 @@ spec:
labels:
app.kubernetes.io/component: {{ .name }}-postgres
spec:
securityContext:
# Run the image entrypoint as postgres so it does not invoke gosu.
runAsUser: 999
runAsGroup: 999
fsGroup: 999
{{ include "mixingx-platform.tierAffinity" (dict "role" .tierRole "root" $root) | nindent 6 }}
{{- with $root.Values.imagePullSecrets }}
imagePullSecrets:
@@ -245,10 +243,6 @@ spec:
- name: postgres
image: {{ $root.Values.sharedInfra.postgres.image | default "docker.io/library/postgres:17" }}
imagePullPolicy: IfNotPresent
command: ["docker-entrypoint.sh", "postgres"]
securityContext:
# Temporary compatibility workaround for checkpoint signal failures on affected k3s nodes.
privileged: true
env:
- name: POSTGRES_PASSWORD
value: "{{ $root.Values.sharedInfra.postgres.password }}"
@@ -262,15 +256,6 @@ spec:
- name: tcp
containerPort: {{ $root.Values.sharedInfra.postgres.port }}
protocol: TCP
readinessProbe:
exec:
command:
- sh
- -ec
- >-
exec pg_isready -q -h 127.0.0.1 -p {{ $root.Values.sharedInfra.postgres.port }} -U "$POSTGRES_USER" -d "$POSTGRES_DB"
periodSeconds: 5
timeoutSeconds: 3
volumeMounts:
- name: data
mountPath: /var/lib/postgresql/data
@@ -213,24 +213,24 @@ spec:
labels:
app.kubernetes.io/component: {{ .Values.audit.database }}-postgres
spec:
securityContext:
# Run the image entrypoint as postgres so it does not invoke gosu.
runAsUser: 999
runAsGroup: 999
fsGroup: 999
{{ include "mixingx-platform.tierAffinity" (dict "role" "audit" "root" $root) | nindent 6 }}
{{- with $.Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
# postgres 以专用用户直跑,绕过镜像内 gosu(新内核下 gosu 用户态死循环,
# 见工单:kernel 7.0.0-39+ × gosu 兼容 bug;三件套缺一不可)
securityContext:
runAsUser: 999
runAsGroup: 999
fsGroup: 999
containers:
- name: postgres
image: {{ $root.Values.sharedInfra.postgres.image | default "docker.io/library/postgres:17" }}
imagePullPolicy: IfNotPresent
command: ["docker-entrypoint.sh", "postgres"]
securityContext:
# Temporary compatibility workaround for checkpoint signal failures on affected k3s nodes.
privileged: true
image: {{ $root.Values.sharedInfra.postgres.image | default "docker.io/library/postgres:17" }}
imagePullPolicy: IfNotPresent
env:
- name: POSTGRES_PASSWORD
value: "{{ $root.Values.sharedInfra.postgres.password }}"
@@ -244,15 +244,6 @@ spec:
- name: tcp
containerPort: {{ $root.Values.sharedInfra.postgres.port }}
protocol: TCP
readinessProbe:
exec:
command:
- sh
- -ec
- >-
exec pg_isready -q -h 127.0.0.1 -p {{ $root.Values.sharedInfra.postgres.port }} -U "$POSTGRES_USER" -d "$POSTGRES_DB"
periodSeconds: 5
timeoutSeconds: 3
volumeMounts:
- name: data
mountPath: /var/lib/postgresql/data
@@ -2,5 +2,5 @@ apiVersion: v2
name: mixingx-protocol-server-unit
description: Deploy one MixingX edge protocol test server instance.
type: application
version: 1.0.91
appVersion: "1.0.91"
version: 1.0.98
appVersion: "1.0.98"
+2 -2
View File
@@ -2,5 +2,5 @@ apiVersion: v2
name: mixingx-sso
description: MixingX SSO standalone release (backend, web, and PostgreSQL).
type: application
version: 1.0.91
appVersion: "1.0.91"
version: 1.0.98
appVersion: "1.0.98"
+11 -17
View File
@@ -36,6 +36,9 @@ spec:
- name: {{ $name }}
image: {{ $root.Values.registry }}/{{ $root.Values.images.sso.repository | default "sso" }}:{{ $root.Values.images.sso.tag | default $root.Values.tag | default "latest" }}
imagePullPolicy: IfNotPresent
securityContext:
appArmorProfile:
type: Unconfined
ports:
- name: http
containerPort: {{ $backendPort }}
@@ -197,24 +200,24 @@ spec:
labels:
app.kubernetes.io/component: {{ $name }}-postgres
spec:
securityContext:
# Run the image entrypoint as postgres so it does not invoke gosu.
runAsUser: 999
runAsGroup: 999
fsGroup: 999
{{ include "mixingx-sso.tierAffinity" (dict "role" $role "root" $root) | nindent 6 }}
{{- with $.Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
# postgres 以专用用户直跑,绕过镜像内 gosu(新内核下 gosu 用户态死循环,
# 见工单:kernel 7.0.0-39+ × gosu 兼容 bug;三件套缺一不可)
securityContext:
runAsUser: 999
runAsGroup: 999
fsGroup: 999
containers:
- name: postgres
image: {{ $root.Values.sharedInfra.postgres.image | default "docker.io/library/postgres:17" }}
imagePullPolicy: IfNotPresent
command: ["docker-entrypoint.sh", "postgres"]
securityContext:
# Temporary compatibility workaround for checkpoint signal failures on affected k3s nodes.
privileged: true
image: {{ $root.Values.sharedInfra.postgres.image | default "docker.io/library/postgres:17" }}
imagePullPolicy: IfNotPresent
env:
- name: POSTGRES_PASSWORD
value: "{{ $root.Values.sharedInfra.postgres.password }}"
@@ -228,15 +231,6 @@ spec:
- name: tcp
containerPort: {{ $root.Values.sharedInfra.postgres.port }}
protocol: TCP
readinessProbe:
exec:
command:
- sh
- -ec
- >-
exec pg_isready -q -h 127.0.0.1 -p {{ $root.Values.sharedInfra.postgres.port }} -U "$POSTGRES_USER" -d "$POSTGRES_DB"
periodSeconds: 5
timeoutSeconds: 3
volumeMounts:
- name: data
mountPath: /var/lib/postgresql/data
+2 -2
View File
@@ -2,5 +2,5 @@ apiVersion: v2
name: mixingx-ultra
description: "MixingX Ultra dashboard standalone release: ultra backend, ultra web, and ultra PostgreSQL."
type: application
version: 1.0.91
appVersion: "1.0.91"
version: 1.0.98
appVersion: "1.0.98"
@@ -41,6 +41,9 @@ spec:
- name: {{ $name }}
image: {{ $root.Values.registry }}/{{ $root.Values.images.ultra.repository | default "ultra" }}:{{ $root.Values.images.ultra.tag | default $root.Values.tag | default "latest" }}
imagePullPolicy: IfNotPresent
securityContext:
appArmorProfile:
type: Unconfined
ports:
- name: http
containerPort: {{ $port }}
@@ -200,24 +203,24 @@ spec:
labels:
app.kubernetes.io/component: {{ $name }}-postgres
spec:
securityContext:
# Run the image entrypoint as postgres so it does not invoke gosu.
runAsUser: 999
runAsGroup: 999
fsGroup: 999
{{ include "mixingx-ultra.tierAffinity" (dict "role" $role "root" $root) | nindent 6 }}
{{- with $.Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
# postgres 以专用用户直跑,绕过镜像内 gosu(新内核下 gosu 用户态死循环,
# 见工单:kernel 7.0.0-39+ × gosu 兼容 bug;三件套缺一不可)
securityContext:
runAsUser: 999
runAsGroup: 999
fsGroup: 999
containers:
- name: postgres
image: {{ $root.Values.sharedInfra.postgres.image | default "docker.io/library/postgres:17" }}
imagePullPolicy: IfNotPresent
command: ["docker-entrypoint.sh", "postgres"]
securityContext:
# Temporary compatibility workaround for checkpoint signal failures on affected k3s nodes.
privileged: true
image: {{ $root.Values.sharedInfra.postgres.image | default "docker.io/library/postgres:17" }}
imagePullPolicy: IfNotPresent
env:
- name: POSTGRES_PASSWORD
value: "{{ $root.Values.sharedInfra.postgres.password }}"
@@ -231,15 +234,6 @@ spec:
- name: tcp
containerPort: {{ $root.Values.sharedInfra.postgres.port }}
protocol: TCP
readinessProbe:
exec:
command:
- sh
- -ec
- >-
exec pg_isready -q -h 127.0.0.1 -p {{ $root.Values.sharedInfra.postgres.port }} -U "$POSTGRES_USER" -d "$POSTGRES_DB"
periodSeconds: 5
timeoutSeconds: 3
volumeMounts:
- name: data
mountPath: /var/lib/postgresql/data