From cdb79f6fd24d0e96575c2e38164c92c8f443ca04 Mon Sep 17 00:00:00 2001 From: qiaofeng1227 <76487013@qq.com> Date: Tue, 8 Nov 2022 09:11:32 +0800 Subject: [PATCH] Update init_without_docker.sh --- apps/roles/bt/templates/init_without_docker.sh | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/apps/roles/bt/templates/init_without_docker.sh b/apps/roles/bt/templates/init_without_docker.sh index b46486be..b77f8bcd 100644 --- a/apps/roles/bt/templates/init_without_docker.sh +++ b/apps/roles/bt/templates/init_without_docker.sh @@ -3,12 +3,7 @@ #!/bin/bash export PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin -newpassword=$1 -# echo $newpassword |passwd --stdin fastuser -echo "fastuser:$newpassword" | chpasswd - -sed -i '/172.17.0.1/d' /etc/nginx/conf.d/parking.conf -internal_ip=$(ip addr show dev eth0|grep inet |grep eth0|cut -d/ -f1|cut -d" " -f6) -old_ip=$(cat /etc/nginx/conf.d/parking.conf |grep default_server|grep ssl |cut -d: -f1|cut -d" " -f6) -sed -i "s/$old_ip/$internal_ip/g" /etc/nginx/conf.d/parking.conf -systemctl restart nginx +new_password=$1 +sudo su +cd /www/server/panel +python tools.py panel $new_password