---
apiVersion: apps/v1
kind: Deployment
metadata:
    name: localname
    labels:
        project: localname
        app: localname
spec:
    replicas: 1
    selector:
        matchLabels:
            app: localname
    template:
        metadata:
            labels:
                project: localname
                app: localname
        spec:
            containers:
                - name: localname
                  image: billglover/localname:arm
                  imagePullPolicy: Always
                  env:
                      - name: LOCALNAME_DOMAIN
                        valueFrom:
                            secretKeyRef:
                                name: localname
                                key: domain
                      - name: LOCALNAME_POLL_FREQ
                        valueFrom:
                            secretKeyRef:
                                name: localname
                                key: freq
                      - name: LOCALNAME_ZONE_ID
                        valueFrom:
                            secretKeyRef:
                                name: localname
                                key: zoneID
                      - name: AWS_ACCESS_KEY_ID
                        valueFrom:
                            secretKeyRef:
                                name: localname
                                key: awsKey
                      - name: AWS_SECRET_ACCESS_KEY
                        valueFrom:
                            secretKeyRef:
                                name: localname
                                key: awsSecret
                  ports:
                      - containerPort: 8080
