...
1apiVersion: v1
2kind: Service
3metadata:
4 name: caller
5 labels:
6 app: caller
7 domain: prod
8 component: kitchen
9spec:
10 ports:
11 - port: 8080
12 protocol: TCP
13 targetPort: 8080
14 name: client
15 selector:
16 app: caller
17 domain: prod
18---
19apiVersion: apps/v1
20kind: Deployment
21metadata:
22 name: caller
23spec:
24 replicas: 3
25 template:
26 metadata:
27 annotations:
28 prometheus.io.scrape: "true"
29 labels:
30 app: caller
31 domain: prod
32 component: kitchen
33 spec:
34 volumes:
35 - name: ssd-caller
36 gcePersistentDisk:
37 # This disk must already exist.
38 pdName: ssd-caller
39 fsType: ext4
40 - name: secret-caller
41 secret:
42 secretName: caller-secrets
43 - name: secret-ssh-key
44 secret:
45 secretName: secrets
46 containers:
47 - image: gcr.io/myproj/caller:v0.20.14
48 volumeMounts:
49 - name: ssd-caller
50 mountPath: /logs
51 - mountPath: /etc/certs
52 name: secret-caller
53 readOnly: true
54 - mountPath: /sslcerts
55 name: secret-ssh-key
56 readOnly: true
57 ports:
58 - containerPort: 8080
59 args: [
60 "-env=prod",
61 "-key=/etc/certs/client.key",
62 "-cert=/etc/certs/client.pem",
63 "-ca=/etc/certs/servfx.ca",
64 "-ssh-tunnel-key=/sslcerts/tunnel-private.pem",
65 "-logdir=/logs",
66 "-event-server=events:7788",
67 ]
68 name: caller
69 livenessProbe:
70 httpGet:
71 path: /debug/health
72 port: 8080
73 initialDelaySeconds: 40
74 periodSeconds: 3
View as plain text