Passing the MapR Data Science Refinery Password as a Secret in Kubernetes
To avoid passing your MAPR_CONTAINER_PASSWORD
in clear text, you can
use a Kubernetes secret. This topic shows you how to do this.
Procedure
-
Create a secret (
dsr-container-secret.yaml
) where you have base64 encodedMAPR_CONTAINER_PASSWORD
:apiVersion: v1 kind: Secret metadata: name: dsr-container-secret type: Opaque data: password: azhzUm9ja3M=
azhzUm9ja3M=
is the base64 encoding ofk8sRocks
. -
Create the secret before deploying your MapR Data Science Refinery
container by running the following command:
kubectl create -f dsr-container-secret.yaml
-
Reference the secret in your deployment YAML file as follows:
- name: MAPR_CONTAINER_PASSWORD valueFrom: secretKeyRef: name: dsr-container-secret key: password