From 002949c29332c7c64b2941a5558fcf08f9a0b22e Mon Sep 17 00:00:00 2001 From: MKody Date: Thu, 15 Jun 2017 18:52:45 +0200 Subject: [PATCH 1/5] Update to ZeroNet v0.5.5 --- conf/app.src | 6 +++--- manifest.json | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/conf/app.src b/conf/app.src index 5a20fe7..1051521 100644 --- a/conf/app.src +++ b/conf/app.src @@ -1,3 +1,3 @@ -SOURCE_URL=https://github.com/HelloZeroNet/ZeroNet/archive/v0.5.2.tar.gz -SOURCE_SUM=cb17031cf0bbf2834ffbae70ec65f436aa83b020a5654054106da104a673a242 -SOURCE_VERSION=0.5.2 +SOURCE_URL=https://github.com/HelloZeroNet/ZeroNet/archive/v0.5.5.tar.gz +SOURCE_SUM=9e39e0925ca7bbda09f2aae0b5b86f13fc96975eb8bac826faa23b250e98b276 +SOURCE_VERSION=0.5.5 diff --git a/manifest.json b/manifest.json index f056d02..d07673d 100644 --- a/manifest.json +++ b/manifest.json @@ -8,7 +8,7 @@ }, "url": "https://zeronet.io", "license": "free", - "version": "0.5.2", + "version": "0.5.5", "maintainer": { "name": "whypsi", "email": "whypsi@riseup.net" From 7857579656790c56caf3922d2b6dbca48d55ad7d Mon Sep 17 00:00:00 2001 From: MKody Date: Thu, 15 Jun 2017 19:02:26 +0200 Subject: [PATCH 2/5] Delete symbolic link before making a new one. Or it'll just create a symolic link _inside_ your symoblic link. Not useful. --- scripts/functions.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/functions.sh b/scripts/functions.sh index 1c2c425..290aca3 100644 --- a/scripts/functions.sh +++ b/scripts/functions.sh @@ -57,6 +57,7 @@ obtain_and_deploy_source() { check_file_integrity $src_file $src_checksum extract_archive $src_file $deploy_path + sudo rm $symlink_to_deploy_path sudo ln --symbolic --force $deploy_path $symlink_to_deploy_path sudo chown $user: -LR $symlink_to_deploy_path From 5e488f188b353148e2881ed0e3abec2d99161d86 Mon Sep 17 00:00:00 2001 From: MKody Date: Sun, 16 Jul 2017 18:36:14 +0200 Subject: [PATCH 3/5] Update to v0.5.6 --- conf/app.src | 6 +++--- manifest.json | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/conf/app.src b/conf/app.src index 1051521..9adbe4e 100644 --- a/conf/app.src +++ b/conf/app.src @@ -1,3 +1,3 @@ -SOURCE_URL=https://github.com/HelloZeroNet/ZeroNet/archive/v0.5.5.tar.gz -SOURCE_SUM=9e39e0925ca7bbda09f2aae0b5b86f13fc96975eb8bac826faa23b250e98b276 -SOURCE_VERSION=0.5.5 +SOURCE_URL=https://github.com/HelloZeroNet/ZeroNet/archive/v0.5.6.tar.gz +SOURCE_SUM=aa3fccf45747c090fe3430593fae4135e5f520e556e260bcc7fd919f6adb1951 +SOURCE_VERSION=0.5.6 diff --git a/manifest.json b/manifest.json index d07673d..9f39003 100644 --- a/manifest.json +++ b/manifest.json @@ -8,7 +8,7 @@ }, "url": "https://zeronet.io", "license": "free", - "version": "0.5.5", + "version": "0.5.6", "maintainer": { "name": "whypsi", "email": "whypsi@riseup.net" From 98d7ee352ca2f0df21a28f3a8fca772c03cfb9e9 Mon Sep 17 00:00:00 2001 From: whypsi Date: Thu, 27 Jul 2017 13:38:06 +0000 Subject: [PATCH 4/5] Sets zeronet --ui_host start parameter to value of yunohost domain the zeronet app is running on. Otherwise access would be denied with "invalid host forbidden". --- conf/systemd.service.template | 2 +- scripts/install | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/conf/systemd.service.template b/conf/systemd.service.template index eebd817..adc5765 100644 --- a/conf/systemd.service.template +++ b/conf/systemd.service.template @@ -4,7 +4,7 @@ After=network.target [Service] User=__USER__ -ExecStart=/usr/bin/python2 ./zeronet.py --ui_port __UI_PORT__ --data_dir __DATA_DIR__ --log_dir __LOG_DIR__ +ExecStart=/usr/bin/python2 ./zeronet.py --ui_port __UI_PORT__ --ui_host __UI_HOST__ --data_dir __DATA_DIR__ --log_dir __LOG_DIR__ WorkingDirectory=__WORKING_DIRECTORY__ ExecReload=/bin/kill -HUP $MAINPID KillMode=process diff --git a/scripts/install b/scripts/install index 4c509a2..b627235 100755 --- a/scripts/install +++ b/scripts/install @@ -50,6 +50,7 @@ update_systemd_configuration() { local port=$6 local symlink_to_deploy_path=$7 local zeronet_dir=$8 + local ui_host=$9 # create zeronet user data location local data_dir=$zeronet_dir/data @@ -64,6 +65,7 @@ update_systemd_configuration() { sudo sed --in-place "s@__USER__@$user@g" $service_file sudo sed --in-place "s@__UI_PORT__@$port@g" $service_file + sudo sed --in-place "s@__UI_HOST__@$ui_host@g" $service_file sudo sed --in-place "s@__APP_NAME__@$app@g" $service_file sudo sed --in-place "s@__WORKING_DIRECTORY__@$symlink_to_deploy_path@g" $service_file sudo sed --in-place "s@__DATA_DIR__@$data_dir@g" $service_file @@ -142,7 +144,7 @@ main() { update_nginx_configuration $app $nginx_config_template $nginx_config_file $path $port update_systemd_configuration $app $systemd_service_template $systemd_service_name $systemd_service_file \ - $user $port $symlink_to_deploy_path $user_zeronet_dir + $user $port $symlink_to_deploy_path $user_zeronet_dir $domain } main From e3bf01e5f97fc885dc3e66d85208ec83d475f156 Mon Sep 17 00:00:00 2001 From: whypsi Date: Thu, 27 Jul 2017 13:53:11 +0000 Subject: [PATCH 5/5] Fixes removal of symbolic link --- scripts/functions.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/functions.sh b/scripts/functions.sh index 290aca3..c970e4c 100644 --- a/scripts/functions.sh +++ b/scripts/functions.sh @@ -57,7 +57,7 @@ obtain_and_deploy_source() { check_file_integrity $src_file $src_checksum extract_archive $src_file $deploy_path - sudo rm $symlink_to_deploy_path + sudo rm -f $symlink_to_deploy_path sudo ln --symbolic --force $deploy_path $symlink_to_deploy_path sudo chown $user: -LR $symlink_to_deploy_path