This commit is contained in:
2024-02-20 17:15:27 +08:00
committed by huty
parent 6706e1a633
commit 34158042ad
1529 changed files with 177765 additions and 0 deletions

View File

@@ -0,0 +1,9 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: vweb-config
labels:
kiamol: ch09
data:
v.txt:
v3.1

View File

@@ -0,0 +1,24 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: vweb
labels:
kiamol: ch09
spec:
replicas: 3
selector:
matchLabels:
app: vweb
template:
metadata:
labels:
app: vweb
version: v1
spec:
containers:
- name: web
image: kiamol/ch09-vweb:v1
ports:
- name: http
containerPort: 80

View File

@@ -0,0 +1,24 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: vweb
labels:
kiamol: ch09
spec:
replicas: 3
selector:
matchLabels:
app: vweb
template:
metadata:
labels:
app: vweb
version: v1.1
spec:
containers:
- name: web
image: kiamol/ch09-vweb:v1
ports:
- name: http
containerPort: 80

View File

@@ -0,0 +1,24 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: vweb
labels:
kiamol: ch09
spec:
replicas: 3
selector:
matchLabels:
app: vweb
template:
metadata:
labels:
app: vweb
version: v2
spec:
containers:
- name: web
image: kiamol/ch09-vweb:v2
ports:
- name: http
containerPort: 80

View File

@@ -0,0 +1,42 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: vweb-config
labels:
kiamol: ch09
data:
v.txt:
v3-from-config
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: vweb
labels:
kiamol: ch09
spec:
replicas: 3
selector:
matchLabels:
app: vweb
template:
metadata:
labels:
app: vweb
version: v3
spec:
containers:
- name: web
image: kiamol/ch09-vweb:v2
ports:
- name: http
containerPort: 80
volumeMounts:
- name: static
mountPath: "/usr/share/nginx/html/"
readOnly: true
volumes:
- name: static
configMap:
name: vweb-config

View File

@@ -0,0 +1,42 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: vweb-config-v4
labels:
kiamol: ch09
data:
v.txt:
v4-from-config
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: vweb
labels:
kiamol: ch09
spec:
replicas: 3
selector:
matchLabels:
app: vweb
template:
metadata:
labels:
app: vweb
version: v4
spec:
containers:
- name: web
image: kiamol/ch09-vweb:v2
ports:
- name: http
containerPort: 80
volumeMounts:
- name: static
mountPath: "/usr/share/nginx/html/"
readOnly: true
volumes:
- name: static
configMap:
name: vweb-config-v4

View File

@@ -0,0 +1,42 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: vweb-config-v41
labels:
kiamol: ch09
data:
v.txt:
v4.1-from-config
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: vweb
labels:
kiamol: ch09
spec:
replicas: 3
selector:
matchLabels:
app: vweb
template:
metadata:
labels:
app: vweb
version: v4.1
spec:
containers:
- name: web
image: kiamol/ch09-vweb:v2
ports:
- name: http
containerPort: 80
volumeMounts:
- name: static
mountPath: "/usr/share/nginx/html/"
readOnly: true
volumes:
- name: static
configMap:
name: vweb-config-v41

View File

@@ -0,0 +1,13 @@
apiVersion: v1
kind: Service
metadata:
name: vweb
labels:
kiamol: ch09
spec:
ports:
- port: 8090
targetPort: http
selector:
app: vweb
type: LoadBalancer

View File

@@ -0,0 +1,24 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: vweb
labels:
kiamol: ch09
spec:
replicas: 2
selector:
matchLabels:
app: vweb
template:
metadata:
labels:
app: vweb
version: v1
spec:
containers:
- name: web
image: kiamol/ch09-vweb:v1
ports:
- name: http
containerPort: 80