Skip to content
Snippets Groups Projects
Commit cf3797fc authored by Dominik Hebeler's avatar Dominik Hebeler
Browse files

Added Container

parent 5364a9bd
No related branches found
No related tags found
2 merge requests!1541Development,!1534Resolve "Optimize Deployment"
...@@ -68,4 +68,4 @@ EXPOSE 80 ...@@ -68,4 +68,4 @@ EXPOSE 80
CMD chown -R root:nginx storage/logs/metager bootstrap/cache && \ CMD chown -R root:nginx storage/logs/metager bootstrap/cache && \
chmod -R g+w storage/logs/metager bootstrap/cache && \ chmod -R g+w storage/logs/metager bootstrap/cache && \
crond -L /dev/stdout && \ crond -L /dev/stdout && \
nginx php-fpm7
...@@ -64,4 +64,4 @@ EXPOSE 80 ...@@ -64,4 +64,4 @@ EXPOSE 80
CMD chown -R root:nginx storage/logs/metager bootstrap/cache && \ CMD chown -R root:nginx storage/logs/metager bootstrap/cache && \
chmod -R g+w storage/logs/metager bootstrap/cache && \ chmod -R g+w storage/logs/metager bootstrap/cache && \
crond -L /dev/stdout && \ crond -L /dev/stdout && \
nginx php-fpm7
...@@ -39,6 +39,42 @@ spec: ...@@ -39,6 +39,42 @@ spec:
persistentVolumeClaim: persistentVolumeClaim:
claimName: mglogs claimName: mglogs
containers: containers:
# Main PHP-FPM Container
- name: {{ .Chart.Name }}-phpfpm
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
{{- if .Values.application.secretName }}
envFrom:
- secretRef:
name: {{ .Values.application.secretName }}
{{- end }}
env:
- name: DATABASE_URL
value: {{ .Values.application.database_url | quote }}
- name: GITLAB_ENVIRONMENT_NAME
value: {{ .Values.gitlab.envName }}
- name: GITLAB_ENVIRONMENT_URL
value: {{ .Values.gitlab.envURL }}
ports:
- name: "{{ .Values.service.name }}-phpfpm"
containerPort: 9000
livenessProbe:
tcpSocket:
port: "{{ .Values.service.name }}-phpfpm"
initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds }}
timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds }}
readinessProbe:
tcpSocket:
port: "{{ .Values.service.name }}-phpfpm"
initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }}
timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }}
volumeMounts:
- name: mglogs-persistent-storage
mountPath: /html/storage/logs/metager
readOnly: false
resources:
{{ toYaml .Values.resources | indent 12 }}
# Nginx Container
- name: {{ .Chart.Name }} - name: {{ .Chart.Name }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}" image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy }} imagePullPolicy: {{ .Values.image.pullPolicy }}
...@@ -81,10 +117,4 @@ spec: ...@@ -81,10 +117,4 @@ spec:
{{- end }} {{- end }}
initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }} initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }}
timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }} timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }}
volumeMounts:
- name: mglogs-persistent-storage
mountPath: /html/storage/logs/metager
readOnly: false
resources:
{{ toYaml .Values.resources | indent 12 }}
{{- end -}} {{- end -}}
...@@ -43,7 +43,6 @@ services: ...@@ -43,7 +43,6 @@ services:
context: . context: .
dockerfile: Dockerfile.dev dockerfile: Dockerfile.dev
image: metager:latest image: metager:latest
command: php-fpm7
working_dir: /html working_dir: /html
volumes: volumes:
- .:/html - .:/html
...@@ -53,6 +52,7 @@ services: ...@@ -53,6 +52,7 @@ services:
restart: on-failure restart: on-failure
image: metager:latest image: metager:latest
working_dir: /html working_dir: /html
command: nginx
volumes: volumes:
- .:/html - .:/html
- ./config/nginx.conf:/etc/nginx/nginx.conf - ./config/nginx.conf:/etc/nginx/nginx.conf
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment