Skip to content

Instantly share code, notes, and snippets.

@ryanhay
Created October 9, 2020 01:04
Show Gist options
  • Save ryanhay/d2e1d1a325e99e98d6db30dbb13357a1 to your computer and use it in GitHub Desktop.
Save ryanhay/d2e1d1a325e99e98d6db30dbb13357a1 to your computer and use it in GitHub Desktop.
apiVersion: v1
kind: Namespace
metadata:
name: helloworld
spec:
finalizers:
- kubernetes
---
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: helloworld-orange
name: helloworld-orange
namespace: helloworld
spec:
progressDeadlineSeconds: 600
replicas: 1
revisionHistoryLimit: 10
selector:
matchLabels:
app: helloworld-orange
strategy:
rollingUpdate:
maxSurge: 25%
maxUnavailable: 25%
type: RollingUpdate
template:
metadata:
creationTimestamp: null
labels:
app: helloworld-orange
spec:
containers:
- image: docker.io/rhay/helloworld:v1
imagePullPolicy: IfNotPresent
name: helloworld-prod
resources: {}
terminationMessagePath: /dev/termination-log
terminationMessagePolicy: File
env:
- name: BG_COLOR
value: orange
dnsPolicy: ClusterFirst
restartPolicy: Always
schedulerName: default-scheduler
securityContext: {}
terminationGracePeriodSeconds: 30
---
apiVersion: v1
kind: Service
metadata:
labels:
app: helloworld-orange
name: helloworld-orange
namespace: helloworld
spec:
externalTrafficPolicy: Cluster
ports:
- nodePort: 30441
port: 80
protocol: TCP
targetPort: 3000
selector:
app: helloworld-orange
sessionAffinity: None
type: LoadBalancer
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment