You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
37 lines
754 B
YAML
37 lines
754 B
YAML
2 years ago
|
apiVersion: apps/v1
|
||
|
kind: Deployment
|
||
|
metadata:
|
||
|
name: nginx
|
||
|
namespace: default
|
||
|
labels:
|
||
|
app: nginx
|
||
|
spec:
|
||
|
replicas: 1
|
||
|
selector:
|
||
|
matchLabels:
|
||
|
app: nginx
|
||
|
template:
|
||
|
metadata:
|
||
|
name: nginx
|
||
|
labels:
|
||
|
app: nginx
|
||
|
spec:
|
||
|
containers:
|
||
|
- name: nginx
|
||
|
image: nginx:latest
|
||
|
imagePullPolicy: IfNotPresent
|
||
|
ports:
|
||
|
- containerPort: 80
|
||
|
protocol: TCP
|
||
|
envFrom:
|
||
|
- configMapRef:
|
||
|
name: nginx-env
|
||
|
volumeMounts:
|
||
|
- name: website-data-volume
|
||
|
mountPath: "/data"
|
||
|
volumes:
|
||
|
- name: website-data-volume
|
||
|
persistentVolumeClaim:
|
||
|
claimName: website-data-pvc
|
||
|
|