Only source mysql_credentials if present in prod install

This commit is contained in:
Stephan Oeste 2022-08-27 15:52:42 +02:00
parent 1a756c5fa9
commit 3b2061bb5c
No known key found for this signature in database
GPG Key ID: 3152347D07DA627C

View File

@ -12,7 +12,10 @@ ELEMENTS_RPC_USER=$(grep '^rpcuser' /elements/elements.conf | cut -d '=' -f2)
ELEMENTS_RPC_PASS=$(grep '^rpcpassword' /elements/elements.conf | cut -d '=' -f2)
# get mysql credentials
. /mempool/mysql_credentials
MYSQL_CRED_FILE=${HOME}/mempool/mysql_credentials
if [ -f "${MYSQL_CRED_FILE}" ];then
. ${MYSQL_CRED_FILE}
}
if [ -f "${LOCKFILE}" ];then
echo "upgrade already running? check lockfile ${LOCKFILE}"