apiVersion: v1
kind: Pod
metadata:
  labels:
    name: weewx
  name: weewx
spec:
  containers:
    - image: mitct02/weewx:latest
      name: weewx
      resources:
        requests:
          cpu: "500m"
          memory: "128Mi"
        limits:
          cpu: "1000m"
          memory: "256Mi"
      volumeMounts:
        - mountPath: "/home/weewx/public_html"
          name: "weewx-html"
    - image: nginx:1.12-alpine
      name: nginx
      volumeMounts:
        - mountPath: "/usr/share/nginx/html"
          name: "weewx-html"
      ports:
      - containerPort: 80
        protocol: TCP
  volumes:
    - name: "weewx-html"
      emptyDir: {}


#apiVersion: apps/v1beta2 # for versions before 1.8.0 use apps/v1beta1
#kind: Deployment
#metadata:
#  name: weewx-deployment
#  labels:
#    app: weewx
#spec:
#  replicas: 1
#  selector:
#    matchLabels:
#      app: weewx
#  template:
#    metadata:
#      labels:
#        app: weewx
#    spec:
#      containers:
#      - name: nginx
#        image: nginx:1.7.9
#        ports:
#        - containerPort: 80




#    ports: # host:container
#      - "80:80"


#      livenessProbe:
#        httpGet:
#          path: /ping
#          port: 8086
#        initialDelaySeconds: 15
#        timeoutSeconds: 1
#      readinessProbe:
#        httpGet:
#          path: /ping
#          port: 8086
#        initialDelaySeconds: 5
#        timeoutSeconds: 1

