open-im-server/script/init_pwd.sh
2022-11-14 18:03:44 +08:00

8 lines
520 B
Bash

#!/usr/bin/env bash
source ../.env
echo "your user is:$USER"
echo "your password is:$PASSWORD"
sed -i "/^\([[:space:]]*dbMysqlUserName: *\).*/s//\1$USER/;/\([[:space:]]*dbUserName: *\).*/s//\1 $USER/;/\([[:space:]]*accessKeyID: *\).*/s//\1$USER/;" ../config/usualConfig.yaml
sed -i "/^\([[:space:]]*dbMysqlPassword: *\).*/s//\1$PASSWORD/;/\([[:space:]]*dbPassword: *\).*/s//\1$PASSWORD/;/\([[:space:]]*dbPassWord: *\).*/s//\1$PASSWORD/;/\([[:space:]]*secretAccessKey: *\).*/s//\1$PASSWORD/;" ../config/usualConfig.yaml