Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
72 lines (68 sloc) 1.12 KB
apiVersion: apps/v1beta1
kind: Deployment
metadata:
name: ${BE_LABEL}
spec:
replicas: 1
template:
metadata:
labels:
app: ${BE_LABEL}
spec:
containers:
- name: ${BE_LABEL}
image: redis
ports:
- containerPort: 6379
name: redis
---
apiVersion: v1
kind: Service
metadata:
name: ${BE_LABEL}
spec:
ports:
- port: 6379
selector:
app: ${BE_LABEL}
---
apiVersion: apps/v1beta1
kind: Deployment
metadata:
name: ${FE_LABEL}
spec:
replicas: 1
strategy:
rollingUpdate:
maxSurge: 1
maxUnavailable: 1
minReadySeconds: 5
template:
metadata:
labels:
app: ${FE_LABEL}
spec:
containers:
- name: ${FE_LABEL}
image: gcr.io/devops-samples/vote:${FE_TAG}
ports:
- containerPort: 80
resources:
requests:
cpu: 250m
limits:
cpu: 500m
env:
- name: REDIS
value: "${BE_LABEL}"
---
apiVersion: v1
kind: Service
metadata:
name: ${FE_LABEL}
spec:
type: LoadBalancer
ports:
- port: 80
selector:
app: ${FE_LABEL}