-
Notifications
You must be signed in to change notification settings - Fork 5
/
kube-deploy.yaml
39 lines (39 loc) · 958 Bytes
/
kube-deploy.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
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
# Unique key of the Deployment instance
name: sample-node-ayeaye
namespace: $ENVIRONMENT
spec:
replicas: $REPLICAS
# Keep record of 10 revisions for rollback
revisionHistoryLimit: 10
progressDeadlineSeconds: 30
minReadySeconds: 5
strategy:
type: RollingUpdate
rollingUpdate:
maxSurge: 1
maxUnavailable: 0
template:
metadata:
labels:
# Apply this label to pods and default
# the Deployment label selector to this value
app: sample-node-ayeaye
env: $ENVIRONMENT
spec:
containers:
- name: sample-node-ayeaye
image: $IMAGE_URL:$IMAGE_TAG
ports:
- containerPort: $PORT
env:
- name: ENVIRONMENT
value: "$ENVIRONMENT"
- name: PORT
value: "$PORT"
resources:
requests:
memory: $MEMORY
cpu: $CPUSHARES