Update init.sh.jinja2

This commit is contained in:
qiaofeng1227 2022-08-23 16:51:58 +08:00 committed by GitHub
parent eb2eee6b4b
commit 2b11d1da58
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -59,7 +59,7 @@ cat /data/apps/{{app_name}}/.env | grep 'APP_USER' |awk -F"=" '{print $1": "$2}'
cat /data/apps/{{app_name}}/.env | grep 'APP_PASSWORD' |awk -F"=" '{print $1": "$2}' >> /credentials/password.txt
cat /data/apps/{{app_name}}/.env |grep APP_|grep PORT |awk -F"=" '{print $1": "$2}' >> /credentials/password.txt
cat /data/apps/{{app_name}}/.env | grep 'DB_' |awk -F"=" '{print $1": "$2}' >> /credentials/password.txt
upper=$(echo {{app_name}} | tr '[A-Z]' '[a-z]')
upper=$(echo {{app_name}} | tr '[a-z]' '[A-Z]')
sudo sed -i "s/APP/$upper/g" /credentials/password.txt
echo " " >> /credentials/password.txt
{% endfor %}