Last active
March 16, 2023 15:47
-
-
Save santisbon/78909fd6775288f905e997de73cd46f3 to your computer and use it in GitHub Desktop.
k8s deployment example #kubernetes #k8s
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
cat <<EOF | kubectl create -f - | |
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
name: nginx-deployment | |
labels: | |
app: nginx | |
spec: | |
replicas: 2 | |
selector: | |
matchLabels: | |
app: nginx | |
template: | |
metadata: | |
labels: | |
app: nginx | |
spec: | |
containers: | |
- name: nginx | |
image: nginx:1.15.4 | |
ports: | |
- containerPort: 80 | |
EOF |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment