1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/etherpad_ynh.git synced 2024-09-03 18:36:10 +02:00

fix niginx conf port bug on upgrade script

This commit is contained in:
Bachir Soussi Chiadmi 2018-05-13 11:28:37 +02:00
parent d876f0894a
commit 26d476e1bd
2 changed files with 6 additions and 5 deletions

View file

@ -1,6 +1,6 @@
location YNH_EXAMPLE_PATH/ {
rewrite ^YNH_EXAMPLE_PATH$ YNH_EXAMPLE_PATH/ permanent;
proxy_pass http://YNH_EXEMPLE_DOMAIN:YNH_EXAMPLE_PORT/;
rewrite ^YNH_PATH$ YNH_PATH/ permanent;
proxy_pass http://YNH_DOMAIN:YNH_PORT/;
proxy_set_header Host $host;
proxy_buffering off;
}

View file

@ -51,9 +51,10 @@ if [ "$path" = "" ]; then
else
sudo cp ../conf/nginx.conf $nginx_conf_path
# Modify Nginx configuration file and copy it to Nginx conf directory
sudo sed -i "s@YNH_EXAMPLE_PATH@$path@g" $nginx_conf_path
sudo sed -i "s@YNH_EXAMPLE_PORT@$port@g" $nginx_conf_path
sudo sed -i "s@YNH_EXEMPLE_DOMAIN@$domain@g" $nginx_conf_path
port='9001'
sudo sed -i "s@YNH_PATH@$path@g" $nginx_conf_path
sudo sed -i "s@YNH_PORT@$port@g" $nginx_conf_path
sudo sed -i "s@YNH_DOMAIN@$domain@g" $nginx_conf_path
fi
# Reload Nginx and regenerate SSOwat conf