diff --git a/k8s/deployment.yaml b/k8s/deployment.yaml index c1ce2ab..329f8fe 100644 --- a/k8s/deployment.yaml +++ b/k8s/deployment.yaml @@ -17,10 +17,12 @@ spec: spec: containers: - name: go-http-app - image: wesleywillians/hello-go:v5 # This image have the fields "NAME" & "AGE" & a file injection on myfamily/family.txt + image: wesleywillians/hello-go:v5.2 # This image have the fields "NAME" & "AGE" & a file injection on myfamily/family.txt envFrom: - configMapRef: name: go-http-app-env + - secretRef: + name: secret-app volumeMounts: - mountPath: "/go/myfamily" name: file-injection diff --git a/k8s/secret.yaml b/k8s/secret.yaml new file mode 100644 index 0000000..ec2bb93 --- /dev/null +++ b/k8s/secret.yaml @@ -0,0 +1,8 @@ +apiVersion: v1 +kind: Secret +metadata: + name: secret-app +type: Opaque +data: + USER: Z2FicmllbAo= + PASSWORD: MTIzNDU2Nwo=