I pass credentials in 2 other cases: MQTT and Postgresql
In Both cases are passed as environment variables into 'configuration nodes'. But Email is not a configuration node.
I use the Dockerfile to pass environment variable like
ENV DB_NAME=db_username
DB_USER=db_password
EMAIL_PASSWORD=my_email_password
...
For instance, right from 'flows.json':
{
"id": "5925e1f25d39f49d",
"type": "postgreSQLConfig",
"name": "RDS-Development R/O",
"host": "${DB_RO_HOST}",
"hostFieldType": "str",
"port": "5432",
"portFieldType": "num",
"database": "${DB_NAME}",
"databaseFieldType": "str",
"ssl": "false",
"sslFieldType": "bool",
"max": "10",
"maxFieldType": "num",
"min": "",
"minFieldType": "",
"idle": "1000",
"idleFieldType": "num",
"connectionTimeout": "10000",
"connectionTimeoutFieldType": "num",
"user": "${DB_USER}",
"userFieldType": "str",
"password": "${DB_PASSWORD}",
"passwordFieldType": "str"
},
I don't use local volumes in docker host as a persistent media, just where that data would remain stored upon restarting or launching a new node-red container. The reason is to facilitate deploying the migration to kubernetes. I did not find a way to migrate persistent volumes from docker to kubernetes.
I am sorry, I know I am missing something here, but trying to figure out what the missing link is. Thank You!!!