-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsymfony-deployment.yaml
45 lines (44 loc) · 1.02 KB
/
symfony-deployment.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: symfony
spec:
replicas: 1
template:
metadata:
labels:
app: symfony
annotations:
pod.alpha.kubernetes.io/init-containers: '[{
"name": "install",
"image": "revsbech/symfonydemo",
"command": ["cp", "-a", "/var/www/application", "/"],
"volumeMounts": [
{
"name": "workdir",
"mountPath": "/application"
}
]
}
]'
spec:
containers:
- name: nginx
image: pcodk/nginx
ports:
- containerPort: 80
volumeMounts:
- mountPath: /var/www/application
name: workdir
- name: php
image: pcodk/php7
volumeMounts:
- mountPath: /var/www/application
name: workdir
- name: mailhog
image: mailhog/mailhog
ports:
- containerPort: 8025
volumes:
- name: workdir
emptyDir: {}