I'm currently facing a weird issue with K8S. Indeed I'm creating a container with an envFrom statement and the env variable is pulled from a secret:
envFrom:
- secretRef:
name: my-super-secret
I have created the secret with the base64 encoded value, and when I echo the variable in the container it has added a space at the end, which is quite an issue since it's a password ;-)
Here's my secret:
apiVersion: v1
kind: Secret
metadata:
name: my-super-secret
data:
DB_PASSWORD: base64encodedvalue
Does anyone could provide me with some guidance here ? I absolutely can't figure out what's happening here ...