mirror of
https://github.com/marcel-dempers/docker-development-youtube-series.git
synced 2025-06-06 17:01:30 +00:00
updates to deploy and secret yaml
This commit is contained in:
parent
1dd2779121
commit
e66d185444
@ -6,7 +6,15 @@ metadata:
|
||||
app: example-app
|
||||
annotations:
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app: example-app
|
||||
replicas: 2
|
||||
strategy:
|
||||
type: RollingUpdate
|
||||
rollingUpdate:
|
||||
maxSurge: 1
|
||||
maxUnavailable: 0
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
@ -31,10 +39,15 @@ spec:
|
||||
limits:
|
||||
memory: "256Mi"
|
||||
cpu: "500m"
|
||||
volumeMouts:
|
||||
- name: config-volume
|
||||
mountPath: /configs/
|
||||
volumes:
|
||||
- name: config-volume
|
||||
configMap:
|
||||
name: example-config #name of our configmap object
|
||||
volumeMounts:
|
||||
- name: secret-volume
|
||||
mountPath: /secrets/
|
||||
- name: config-volume
|
||||
mountPath: /configs/
|
||||
volumes:
|
||||
- name: secret-volume
|
||||
secret:
|
||||
secretName: mysecret
|
||||
- name: config-volume
|
||||
configMap:
|
||||
name: example-config #name of our configmap object
|
12
kubernetes/secrets/secret.yaml
Normal file
12
kubernetes/secrets/secret.yaml
Normal file
@ -0,0 +1,12 @@
|
||||
apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: mysecret
|
||||
type: Opaque
|
||||
stringData:
|
||||
secret.json: |-
|
||||
{
|
||||
"api_key" : "somesecretgoeshere"
|
||||
}
|
||||
|
||||
#kubectl create secret generic mysecret --from-file .\golang\secrets\secret.json
|
Loading…
x
Reference in New Issue
Block a user