fix(helm): права на keystore — fsGroup + chmod 0644 в init
Шлюз в кубе падал с EACCES при записи .gateway-bettors.json: том от local-path принадлежит root, контейнер бежит под node (uid 1000), а seed-файл копировался в режиме 0444. Добавлены securityContext.fsGroup=1000 и chmod 0644 в init-контейнере. Проверено: ставка и закрытие проходят через живой домен (entryPrice/exitPrice — реальные цены из NATS).
This commit is contained in:
@@ -14,6 +14,12 @@ spec:
|
|||||||
labels:
|
labels:
|
||||||
{{- include "smart-updown-relayer.selectorLabels" . | nindent 8 }}
|
{{- include "smart-updown-relayer.selectorLabels" . | nindent 8 }}
|
||||||
spec:
|
spec:
|
||||||
|
# PVC (local-path) создаётся root-владельцем, а контейнер бежит под node (uid 1000).
|
||||||
|
# fsGroup делает смонтированный volume записываемым для группы node — иначе
|
||||||
|
# gateway падает с EACCES при записи keystore новых бетторов.
|
||||||
|
securityContext:
|
||||||
|
fsGroup: 1000
|
||||||
|
fsGroupChangePolicy: OnRootMismatch
|
||||||
{{- with .Values.imagePullSecrets }}
|
{{- with .Values.imagePullSecrets }}
|
||||||
imagePullSecrets:
|
imagePullSecrets:
|
||||||
{{- toYaml . | nindent 8 }}
|
{{- toYaml . | nindent 8 }}
|
||||||
@@ -25,7 +31,7 @@ spec:
|
|||||||
command:
|
command:
|
||||||
- sh
|
- sh
|
||||||
- -c
|
- -c
|
||||||
- '[ -f /app/data/.gateway-bettors.json ] || cp /seed/.gateway-bettors.json /app/data/.gateway-bettors.json'
|
- '[ -f /app/data/.gateway-bettors.json ] || cp /seed/.gateway-bettors.json /app/data/.gateway-bettors.json; chmod 0644 /app/data/.gateway-bettors.json'
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- name: data
|
- name: data
|
||||||
mountPath: /app/data
|
mountPath: /app/data
|
||||||
|
|||||||
Reference in New Issue
Block a user