Writable secrets that can be consumed

This commit is contained in:
2025-11-05 21:41:39 +01:00
parent 2271827ec5
commit a8a01b81b5
4 changed files with 77 additions and 4 deletions

View File

@@ -15,6 +15,22 @@ spec:
spec:
imagePullSecrets:
- name: ghcr-secret
initContainers:
- name: copy-secrets
image: busybox
command:
- sh
- -c
- |
for f in /secrets/*; do
cp "$f" /etc/secrets/
chmod 666 "/etc/secrets/$(basename $f)"
done
volumeMounts:
- name: service-royalroad-chapters-secrets
mountPath: /secrets
- name: writable-secrets
mountPath: /etc/secrets
containers:
- name: service-royalroad-chapters
image: ghcr.io/gansejunge/app-notifications-service-royalroad-chapters:16
@@ -29,10 +45,12 @@ spec:
- name: BACKEND_API_URL
value: "http://backend-api-internal.app-notifications.svc.cluster.local:8101/internal/receive-notifications"
volumeMounts:
- name: service-royalroad-chapters-secrets
- name: writable-secrets
mountPath: /etc/secrets
readOnly: true
volumes:
- name: service-royalroad-chapters-secrets
secret:
secretName: service-royalroad-chapters
- name: writable-secrets
emptyDir: {}