Skip to content

Instantly share code, notes, and snippets.

@PawelHaracz
Created November 30, 2024 19:52
Show Gist options
  • Save PawelHaracz/c56f5b8bf72eeabf7013ba31e041099c to your computer and use it in GitHub Desktop.
Save PawelHaracz/c56f5b8bf72eeabf7013ba31e041099c to your computer and use it in GitHub Desktop.
apiVersion: apps/v1
kind: Deployment
metadata:
name: hellofromnode-deployment
labels:
environment: dev
app: hellofromnode
spec:
replicas: 1
template:
metadata:
name: hellofromnode
labels:
app: hellofromnode
spec:
nodeSelector:
"kubernetes.io/os": linux
containers:
- name: hellofromnode
image: ACR_NAME.azurecr.io/hellofromnode:v1.0
livenessProbe:
httpGet:
path: /
port: 80
initialDelaySeconds: 10
periodSeconds: 10
timeoutSeconds: 2
failureThreshold: 3
readinessProbe:
httpGet:
path: /
port: 80
initialDelaySeconds: 5
periodSeconds: 5
timeoutSeconds: 2
failureThreshold: 2
resources:
limits:
cpu: "1000m"
memory: "80Mi"
ports:
- containerPort: 80
selector:
matchLabels:
app: hellofromnode
---
apiVersion: v1
kind: Service
metadata:
name: hellofromnode-service
spec:
type: LoadBalancer
ports:
- protocol: TCP
port: 80
selector:
app: hellofromnode
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment