Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fauzan-n/2da72824d8321a1dc6c30130ab9801f6 to your computer and use it in GitHub Desktop.
Save fauzan-n/2da72824d8321a1dc6c30130ab9801f6 to your computer and use it in GitHub Desktop.
apiVersion: apps/v1beta2
kind: Deployment
metadata:
name: app-name-example
namespace: default
spec:
replicas: 2
selector:
matchLabels:
app: app-name-example
spec:
containers:
- env:
- name: DB_HOST
valueFrom:
configMapKeyRef:
key: db_host
name: globalenv
- name: DB_USER
valueFrom:
configMapKeyRef:
key: db_user
name: globalenv
- name: DB_PASSWD
valueFrom:
secretKeyRef:
key: db_passwd
name: globalsec
- name: ENVIRONMENT
valueFrom:
configMapKeyRef:
key: environment
name: globalenv
image: >-
examplerepo/app-name-example:latest
name: app-name-example
ports:
- containerPort: 8080
protocol: TCP
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment