apiVersion: v1
kind: Pod
metadata:
  name: mon-web-server
  labels:
    app: my-app-mon-web-server
spec:
  containers:
    - name: bastion
      image: amouat/network-utils
      imagePullPolicy: Always
      ports:
        - containerPort: 8080
          name: mon-port-http
      command: [ 'sh', '-c', 'trap : TERM INT; sleep infinity & wait' ]
      resources:
        requests:
          memory: "64Mi"
          cpu: "250m"
        limits:
          memory: "128Mi"
          cpu: "500m"
      securityContext:
        allowPrivilegeEscalation: false
        runAsNonRoot: true
        capabilities:
          drop:
            - all
          #add: ["..."]

    - name: web-server
      image: nginx:1.17.4
      imagePullPolicy: Always
      ports:
        - containerPort: 8080
          name: mon-port-http
      volumeMounts:
        - name: my-volume-mon-web-server
          mountPath: "/usr/share/nginx/html"
      resources:
        requests:
          memory: "64Mi"
          cpu: "250m"
        limits:
          memory: "128Mi"
          cpu: "500m"
      securityContext:
        allowPrivilegeEscalation: false
        runAsNonRoot: true
        capabilities:
          drop:
            - all
          #add: ["..."]
  volumes:
    - name: my-volume-mon-web-server
      persistentVolumeClaim:
        claimName: static-web-site