nginx-http-deploy.yml 669 B

1234567891011121314151617181920212223242526272829303132
  1. apiVersion: apps/v1
  2. kind: Deployment
  3. metadata:
  4. name: nginx-http
  5. spec:
  6. replicas: 1
  7. selector:
  8. matchLabels:
  9. app: nginx-http
  10. template:
  11. metadata:
  12. labels:
  13. app: nginx-http
  14. spec:
  15. containers:
  16. - name: nginx-http
  17. image: nginx
  18. ports:
  19. - name: web
  20. containerPort: 80
  21. volumeMounts:
  22. - name: nginx-http-cm
  23. mountPath: /etc/nginx
  24. - name: nginx-http-vol
  25. mountPath: /usr/share/nginx/html
  26. volumes:
  27. - name: nginx-http-cm
  28. configMap:
  29. name: nginx-http-cm
  30. - name: nginx-http-vol
  31. hostPath:
  32. path: /var/nginxserver