1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/jappix_ynh.git synced 2024-09-03 19:26:19 +02:00

[enh] add name choice

This commit is contained in:
mbugeia 2014-11-25 22:20:01 +01:00
parent 9dbb09f103
commit 2570a41125
3 changed files with 8 additions and 0 deletions

View file

@ -37,6 +37,7 @@ then
language="en"
fi
sudo yunohost app setting jappix name -v $language
sudo yunohost app setting jappix language -v $language
sudo sed -i "s@PATHTOCHANGE@$path@g" ../conf/nginx.conf

View file

@ -6,6 +6,7 @@ sudo rm -f /etc/nginx/conf.d/$domain.d/jappix.conf
sudo yunohost app setting jappix domain -d
sudo yunohost app setting jappix path -d
sudo yunohost app setting jappix name -d
sudo yunohost app setting jappix language -d
sudo service nginx reload

View file

@ -3,8 +3,13 @@
# Retrieve arguments
domain=$(sudo yunohost app setting jappix domain)
path=$(sudo yunohost app setting jappix path)
name=$(sudo yunohost app setting jappix path)
language=$(sudo yunohost app setting jappix language)
if [[ "$name" = "" ]];
then
name="YunoJappix"
fi
if [[ "$language" = "" ]];
then
language="en"
@ -37,6 +42,7 @@ sudo sed -i "s@PATHTOCHANGE@$path@g" $final_path/store/conf/main.xml
sudo sed -i "s@PATHTOCHANGE@$path@g" $final_path/store/conf/hosts.xml
sudo sed -i "s@DOMAINTOCHANGE@$domain@g" $final_path/store/conf/main.xml
sudo sed -i "s@CHANGELANG@$language@g" $final_path/store/conf/main.xml
sudo sed -i "s@CHANGENAME@$name@g" $final_path/store/conf/main.xml
sudo sed -i "s@DOMAINTOCHANGE@$domain@g" $final_path/store/conf/hosts.xml
# Reload Nginx and regenerate SSOwat conf