-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathk8s.yml
61 lines (61 loc) · 1.43 KB
/
k8s.yml
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
apiVersion: apps/v1
kind: Deployment
metadata:
name: spot-app
namespace: workshop
labels:
app: spot
spec:
replicas: 4
selector:
matchLabels:
app: spot
template:
metadata:
labels:
app: spot
spec:
containers:
- name: spot-service
image: lobostome/spot:v1
imagePullPolicy: Always
ports:
- containerPort: 8080
resources:
limits:
cpu: "0.5"
memory: "200Mi"
requests:
cpu: "100m" # 100 milliCPU == 0.1
memory: "100Mi" # 100 mebibytes; 1MiB = 2^20 bytes
readinessProbe:
failureThreshold: 3
httpGet:
path: /health
port: 8080
scheme: HTTP
initialDelaySeconds: 5
periodSeconds: 10
successThreshold: 1
timeoutSeconds: 1
livenessProbe:
failureThreshold: 3
httpGet:
path: /health
port: 8080
scheme: HTTP
initialDelaySeconds: 5
periodSeconds: 10
successThreshold: 1
timeoutSeconds: 1
# env:
# - name: NAME
# valueFrom:
# configMapKeyRef:
# name: configmap-app-name
# key: NAME
# - name: NAME
# valueFrom:
# secretKeyRef:
# name: secret-app-name
# key: NAME