Created
August 14, 2021 18:12
-
-
Save thecraftman/b3cd7dc0cffdb527f832829dbeaafa9c to your computer and use it in GitHub Desktop.
Generate secrets for Kubernetes using env
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: v1 | |
kind: Pod | |
metadata: | |
name: hello-world.example.com | |
labels: | |
app: hello-world | |
spec: | |
containers: | |
- name: docker-demo | |
image: tolatemitope/docker-demo | |
ports: | |
- name: python-port | |
containerPort: 5000 | |
env: | |
- name: SECRET_USERNAME | |
valueFrom: | |
secretKeyRef: | |
name: db-secret | |
key: username | |
- name: SECRET_PASSWORD |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment