Skip to content

Instantly share code, notes, and snippets.

@leandronsp
Last active February 21, 2023 20:46
Show Gist options
  • Save leandronsp/0dd7a3a3600fe23ecac1d41157373b4f to your computer and use it in GitHub Desktop.
Save leandronsp/0dd7a3a3600fe23ecac1d41157373b4f to your computer and use it in GitHub Desktop.
Running Chespirito in Kubernetes
apiVersion: apps/v1
metadata:
labels:
app: chespirito-pod
name: chespirito-pod
spec:
replicas: 1
selector:
matchLabels:
app: chespirito-pod
template:
metadata:
labels:
app: chespirito-pod
spec:
containers:
## Because I'm running k8s in colima, `colima` is the node hostname as the `31320`
### is the NodePort
- image: colima:31320/chespirito
imagePullPolicy: Always
name: app
ports:
- containerPort: 3000
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: registry-pod
name: registry-pod
spec:
replicas: 1
selector:
matchLabels:
app: registry-pod
template:
metadata:
labels:
app: registry-pod
spec:
containers:
- image: registry:2
name: registry
ports:
- containerPort: 5000
---
apiVersion: v1
kind: Service
metadata:
name: registry-svc
labels:
app: registry-svc
spec:
type: NodePort
selector:
app: registry-pod
ports:
- protocol: TCP
nodePort: 31320
port: 5000
targetPort: 5000
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment