Jelajahi Sumber

modify '修改install.sh'

Zhipeng 4 tahun lalu
induk
melakukan
6e8abd426b
1 mengubah file dengan 14 tambahan dan 0 penghapusan
  1. 14 0
      supervisor/install.sh

+ 14 - 0
supervisor/install.sh

@@ -24,3 +24,17 @@ exit 1
 else
 # The first position is server.conf File installation directory
 cp server.conf $served/$conf
+fi
+
+#替换变量
+
+sed -i "s#PROGRAM#$program#g" $served/$conf
+sed -i "s#PROCESS_NAME#$process_name#g" $served/$conf
+sed -i "s#USER#$user#g" $served/$conf
+sed -i "s#DIRECTORY#$directory#g" $served/$conf
+sed -i "s#COMMAND#$command#g" $served/$conf
+
+
+#重读supervisor配置文件
+supervisorctl update
+