apiVersion: apps/v1
kind: Deployment
metadata:
  name: strapi
  labels:
    name: strapi 
spec:
  replicas: 1
  selector:
    matchLabels:
      app: strapi
  template:
    metadata:
      labels:
        app: strapi
    spec:
      containers:
        - name: strapi
          image: bketelsen/content:10
          imagePullPolicy: Always
          env:
            - name: DATABASE_NAME
              value: "strapi"
            - name: DATABASE_HOST
              value: "private-gophercon-do-user-167863-0.b.db.ondigitalocean.com"
            - name: DATABASE_PORT
              value: "25060"
            - name: DATABASE_USERNAME
              value: "strapi"
            - name: DATABASE_PASSWORD
              valueFrom:
                secretKeyRef:
                  name: strapi-db-secret
                  key: password
          ports:
            - name: strapi-port
              containerPort: 1337
              protocol: TCP
