test theme volume mount

This commit is contained in:
Matthieu Lamalle 2023-07-03 11:24:45 +02:00
parent 9a4ffcee83
commit 3ac04dd27e

View File

@ -16,6 +16,24 @@ spec:
labels: labels:
io.kompose.service: hydra-dispatcher io.kompose.service: hydra-dispatcher
spec: spec:
initContainers:
# This container clones the desired git repo to the EmptyDir volume.
- name: git-theme
image: alpine/git # Any image with git will do
args:
- clone
- --single-branch
- --
- https://forge.cadoles.com/CNOUS/hydra-dispatcher-mse-theme.git # Your repo
- /theme # Put it in the volume
securityContext:
runAsUser: 1 # Any non-root user will do. Match to the workload.
allowPrivilegeEscalation: false
readOnlyRootFilesystem: true
volumeMounts:
- name: git-theme
mountPath: /theme
containers: containers:
- name: hydra-dispatcher-php-fpm - name: hydra-dispatcher-php-fpm
image: reg.cadoles.com/cadoles/hydra-dispatcher-kube:0.0.1 image: reg.cadoles.com/cadoles/hydra-dispatcher-kube:0.0.1
@ -31,8 +49,10 @@ spec:
- configMapRef: - configMapRef:
name: hydra-dispatcher-env name: hydra-dispatcher-env
volumeMounts: volumeMounts:
- mountPath: /app/config/hydra - name: hydra-dispatcher-apps
name: hydra-dispatcher-apps mountPath: /app/config/hydra
- name: git-theme
mountPath: /theme
resources: {} resources: {}
- image: reg.cadoles.com/cadoles/hydra-dispatcher-kube:0.0.1 - image: reg.cadoles.com/cadoles/hydra-dispatcher-kube:0.0.1
@ -61,3 +81,5 @@ spec:
- name: hydra-dispatcher-apps - name: hydra-dispatcher-apps
configMap: configMap:
name: hydra-dispatcher-apps name: hydra-dispatcher-apps
- name: git-theme
emptyDir: {}