Last active
October 25, 2017 15:47
-
-
Save martincalvert/a2a531eba2068e9100749ce23d8cee00 to your computer and use it in GitHub Desktop.
K8s: Deployments
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: extensions/v1beta1 | |
kind: Deployment | |
metadata: | |
name: {{ .Chart.Name }} | |
labels: | |
chart: {{ .Chart.Name }}-{{ .Chart.Version }} | |
spec: | |
replicas: {{ .Values.api.replicas }} | |
template: | |
metadata: | |
labels: | |
layer: backend | |
annotations: | |
createdAt: {{ .Release.Time.Seconds | quote }} | |
spec: | |
containers: | |
- name: api | |
image: {{ .Values.api.image.name }} | |
imagePullPolicy: {{ .Values.api.image.pullPolicy }} | |
command: | |
- bundle | |
- exec | |
- unicorn | |
- "-c" | |
- /etc/api/unicorn.rb | |
ports: | |
- containerPort: 8080 | |
readinessProbe | |
httpGet: | |
path: /health.json | |
port: 8080 | |
initialDelaySeconds: 30 | |
periodSeconds: 2 | |
timeoutSeconds: 1 | |
livenessProbe | |
httpGet: | |
path: /health.json | |
port: 8080 | |
initialDelaySeconds: 60 | |
periodSeconds: 15 | |
timeoutSeconds: 2 | |
volumeMounts: | |
- mountPath: /etc/matterhorn/unicorn.rb | |
subPath: unicorn.rb | |
name: unicorn-configmap | |
readOnly: true | |
volumes: | |
- name: unicorn-configmap | |
configMap: | |
name: unicorn-rb-configmap | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
api: | |
image: | |
name: gcr.io/api:latest | |
pullPolicy: always | |
replicas: 5 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment