apiVersion: v1
kind: Pod
metadata:
  name: pod-variable
  namespace: octank
spec:
  containers:
  - name: database
    image: busybox
    command: ["/bin/sh"]
    args: ["-c", "echo DATABASE_USER =  $DATABASE_USER; echo DATABASE_PASSWROD = $DATABASE_PASSWORD; while true; do sleep 1; done"]
    env:
    - name: DATABASE_USER
      valueFrom:
        secretKeyRef:
          name: database-credentials
          key: username
    - name: DATABASE_PASSWORD
      valueFrom:
        secretKeyRef:
          name: database-credentials
          key: password          

