Skip to content

Instantly share code, notes, and snippets.

@benbonnet
Created December 21, 2017 16:00
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save benbonnet/856ebe1a8e656cbc2c456b2b83adc918 to your computer and use it in GitHub Desktop.
Save benbonnet/856ebe1a8e656cbc2c456b2b83adc918 to your computer and use it in GitHub Desktop.
kind: Deployment
apiVersion: "extensions/v1beta1"
metadata:
name: "app"
spec:
replicas: 2
revisionHistoryLimit: 2
template:
metadata:
labels:
service: "app"
spec:
containers:
- name: "app"
image: "eu.gcr.io/project/app"
imagePullPolicy: Always
resources:
requests:
cpu: "64m"
memory: "100Mi"
volumeMounts:
- name: app-defaults
mountPath: /app/config/application.yml
subPath: application.yml
ports:
- containerPort: 3000
volumes:
- name: app-defaults
secret:
secretName: app-defaults
---
kind: Service
apiVersion: v1
metadata:
name: "app"
labels:
service: "app"
spec:
type: NodePort
sessionAffinity: ClientIP
ports:
- port: 3000
targetPort: 3000
selector:
service: "app"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment