diff --git a/README.md b/README.md index 8127732..2240618 100644 --- a/README.md +++ b/README.md @@ -3,4 +3,9 @@ Movim for Yunohost. Movim is a decentralized social network, written in PHP and HTML5 and based on the XMPP standard protocol. +PACKAGE NOT READY YET +DO NOT USE + +**Changelog** + Current Movim version : 20150731. diff --git a/TODO b/TODO index d99832e..70e13f6 100644 --- a/TODO +++ b/TODO @@ -1,4 +1,3 @@ -- SSO / no SSO distinction - Change port ? - SHA password - URL rewriting diff --git a/conf/movim.init b/conf/movim.init index 60c0473..c57aa91 100755 --- a/conf/movim.init +++ b/conf/movim.init @@ -10,7 +10,7 @@ ### END INIT INFO dir="YHDIR" -cmd="php daemon.php https://YHURL 8080" +cmd="php daemon.php https://YHURL YHPORT" user="www-data" name=`basename $0` diff --git a/conf/movim.service b/conf/movim.service index 4846e5e..c237d9d 100644 --- a/conf/movim.service +++ b/conf/movim.service @@ -5,7 +5,7 @@ After=nginx.service network.target local-fs.target [Service] User=www-data Type=simple -ExecStart=/usr/bin/php daemon.php https://YHURL 8080 +ExecStart=/usr/bin/php daemon.php https://YHURL YHPORT WorkingDirectory=YHDIR [Install] diff --git a/conf/nginx.conf b/conf/nginx.conf index bd21e50..e282b51 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -19,7 +19,7 @@ location PATHTOCHANGE { } location ~ ^PATHTOCHANGE/ws/ { - proxy_pass http://localhost:8080; + proxy_pass http://localhost:YHPORT; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "Upgrade"; diff --git a/manifest.json b/manifest.json index 3ae90a8..26e4bae 100644 --- a/manifest.json +++ b/manifest.json @@ -66,7 +66,15 @@ }, "choices": ["Yes", "No"], "default": "No" - } + }, + { + "name": "port", + "ask": { + "en": "Movim daemon port ? (internal only)", + "fr": "Port privé pour Movim ? (interne uniquement)" + }, + "example": "9537" + }, ] } } diff --git a/scripts/install b/scripts/install index dc894f2..bd68566 100644 --- a/scripts/install +++ b/scripts/install @@ -7,6 +7,7 @@ admin=$3 password=$4 language=$5 public_site=$6 +port=$7 # Check domain/path availability sudo yunohost app checkurl $domain$path -a movim @@ -58,6 +59,7 @@ sudo yunohost app addaccess movim -u $admin # Copy init script or systemd service sudo sed -i "s@YHURL@$domain$path@g" ../conf/movim.{service,init} sudo sed -i "s@YHDIR@$final_path@g" ../conf/movim.{service,init} +sudo sed -i "s@YHPORT@$port@g" ../conf/movim.{service,init} if [ `pgrep -ox systemd` = "1" ]; then sudo cp ../conf/movim.service /lib/systemd/system/ @@ -73,6 +75,7 @@ fi # Nginx configuration sed -i "s@PATHTOCHANGE@$path@g" ../conf/nginx.conf sed -i "s@ALIASTOCHANGE@$final_path/@g" ../conf/nginx.conf +sed -i "s@YHPORT@$port@g" ../conf/nginx.conf sudo cp ../conf/nginx.conf /etc/nginx/conf.d/$domain.d/movim.conf # SSOwat Configuration