apiVersion: apps/v1
kind: Deployment
metadata:
  name: d3-deployment
  labels:
    app: d3
spec:
  replicas: 1
  selector:
    matchLabels:
      app: d3
  template:
    metadata:
      labels:
        app: d3
    spec:
      containers:
      - name: d3
        image: dooodle/vis-d3:latest
        imagePullPolicy: Always
        ports:
        - containerPort: 8080
        env:
          - name: VIS_MONDIAL_USER
            valueFrom:
              configMapKeyRef:
                name: vis-simple-config-map
                key: VIS_MONDIAL_USER
          - name: VIS_MONDIAL_PASSWORD
            valueFrom:
              configMapKeyRef:
                name: vis-simple-config-map
                key: VIS_MONDIAL_PASSWORD
          - name: VIS_MONDIAL_HOST
            valueFrom:
              configMapKeyRef:
                name: vis-simple-config-map
                key: VIS_MONDIAL_HOST
          - name: VIS_MONDIAL_PORT
            valueFrom:            
               configMapKeyRef:
                name: vis-simple-config-map
                key: VIS_MONDIAL_PORT
          - name: VIS_MONDIAL_SSLMODE
            valueFrom:            
              configMapKeyRef:
                name: vis-simple-config-map
                key: VIS_MONDIAL_SSLMODE
          - name: VIS_MONDIAL_DBNAME
            valueFrom:            
              configMapKeyRef:
                name: vis-simple-config-map
                key: VIS_MONDIAL_DBNAME
