apiVersion: v1
kind: Pod
metadata:
  name: configmap-and-secret-pod
spec:
  containers:
    - name: nginx-configmap-and-secret
      image: nginx
      command: ['/bin/bash', '-c', 'cat /etc/app-data/application.properties; cat /etc/secure-data/application-secure.properties']
      volumeMounts:
        - name: configmap-volume
          mountPath: /etc/app-data
        - name: secrets-volume
          mountPath: /etc/secure-data
  volumes:
    - name: configmap-volume
      configMap:
        name: my-app-data
    - name: secrets-volume
      secret:
        secretName: my-app-secret

