renamed & updated kubernetes example asset

This commit is contained in:
2025-01-18 12:09:53 +01:00
parent 73e92a115a
commit ad64b7728b
2 changed files with 42 additions and 21 deletions

View File

@@ -1,21 +0,0 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginx-deployment
labels:
app: nginx
spec:
replicas: 3
selector:
matchLabels:
app: nginx
template:
metadata:
labels:
app: nginx
spec:
containers:
- name: nginx
image: nginx:1.14.2
ports:
- containerPort: 80

42
assets/kubernetes.yml Normal file
View File

@@ -0,0 +1,42 @@
apiVersion: v1
kind: Service
metadata:
name: example-webapp
labels:
app: example-webapp
annotations:
traefik.ingress.kubernetes.io/router.entrypoints: "web"
traefik.ingress.kubernetes.io/router.rule: "Host(`example.com`)"
spec:
selector:
app: example-webapp
ports:
- protocol: TCP
port: 80
targetPort: 80
type: ClusterIP
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: example-webapp
labels:
app: example-webapp
spec:
replicas: 2
selector:
matchLabels:
app: example-webapp
template:
metadata:
labels:
app: example-webapp
annotations:
traefik.ingress.kubernetes.io/router.entrypoints: "web"
traefik.ingress.kubernetes.io/router.rule: "Host(`example.com`)"
spec:
containers:
- name: webapp
image: nginx:latest
ports:
- containerPort: 80