From 352a6c0602398dca5242dd0c31fd8a8564e14e70 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 30 Apr 2023 15:37:33 +0200 Subject: [PATCH] fix --- conf/nginx.conf | 34 +++++++++++++++++++--------------- manifest.toml | 8 +++++++- scripts/install | 14 ++++++++++---- 3 files changed, 36 insertions(+), 20 deletions(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index 087602d..19388a8 100755 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -1,3 +1,22 @@ +#sub_path_only rewrite ^__PATH__$ __PATH__/ permanent; +location __PATH__/ { + + proxy_pass http://127.0.0.1:__PORT__/; + proxy_redirect off; + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-Proto $scheme; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Forwarded-Host $server_name; + + proxy_http_version 1.1; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection "upgrade"; + + # Include SSOWAT user panel. + include conf.d/yunohost_panel.conf.inc; +} + location /auth/ { proxy_pass http://127.0.0.1:__PORT_LDAP__/; @@ -12,18 +31,3 @@ location /auth/ { proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; } - -location / { - - proxy_pass http://127.0.0.1:__PORT__/; - proxy_redirect off; - proxy_set_header Host $host; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-Proto $scheme; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - proxy_set_header X-Forwarded-Host $server_name; - - proxy_http_version 1.1; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection "upgrade"; -} diff --git a/manifest.toml b/manifest.toml index 1552b00..0c0a52e 100644 --- a/manifest.toml +++ b/manifest.toml @@ -18,7 +18,7 @@ userdoc = "https://galene.org/faq.html" code = "https://github.com/jech/galene" [integration] -yunohost = ">= 11.1.17" +yunohost = ">= 11.1.18" architectures = "all" multi_instance = false ldap = true @@ -75,6 +75,12 @@ ram.runtime = "50M" autoupdate.upstream = "https://github.com/jech/galene-ldap" autoupdate.strategy = "latest_github_commit" + [resources.sources.transferarchive] + url = "https://github.com/jech/galene-file-transfer/archive/8ad893eb75de0fb25958a77183ab52d19430d27a.tar.gz" + sha256 = "afdf2ee4df933824b92cfb3aec1e733b38e46571d007377116fdf789db8b7bc6" + autoupdate.upstream = "https://github.com/jech/galene-file-tranfer" + autoupdate.strategy = "latest_github_commit" + [resources.system_user] [resources.install_dir] diff --git a/scripts/install b/scripts/install index 2f31bab..2fc068b 100755 --- a/scripts/install +++ b/scripts/install @@ -35,6 +35,7 @@ ynh_script_progression --message="Setting up source files..." --weight=1 # Download, check integrity, uncompress and patch the source from app.src ynh_setup_source --dest_dir="$install_dir/build" ynh_setup_source --dest_dir="$install_dir/build_ldap" --source_id="ldap" +ynh_setup_source --dest_dir="$install_dir/build_transferarchive" --source_id="transferarchive" mkdir -p "$install_dir/live/data" mkdir -p "$install_dir/live_ldap/data" @@ -63,10 +64,6 @@ ynh_script_progression --message="Building app..." --weight=1 ynh_exec_warn_less ynh_install_go --go_version=$go_version ynh_use_go -pushd $install_dir/build/galene-password-generator/ - ynh_exec_warn_less ynh_exec_as $app CGO_ENABLED=0 $ynh_go build -o $install_dir/ -popd - pushd $install_dir/build/ ynh_exec_warn_less ynh_exec_as $app CGO_ENABLED=0 $ynh_go build -ldflags='-s -w' -o $install_dir/live/ popd @@ -75,9 +72,18 @@ pushd $install_dir/build_ldap/ ynh_exec_warn_less ynh_exec_as $app CGO_ENABLED=0 $ynh_go build -ldflags='-s -w' -o $install_dir/live_ldap/ popd +pushd $install_dir/build/galene-password-generator/ + ynh_exec_warn_less ynh_exec_as $app CGO_ENABLED=0 $ynh_go build -o $install_dir/ +popd + +pushd $install_dir/build_transferarchive/ + ynh_exec_warn_less ynh_exec_as $app CGO_ENABLED=0 $ynh_go build -o $install_dir/ +popd + ynh_remove_go ynh_secure_remove --file="$install_dir/build/" ynh_secure_remove --file="$install_dir/build_ldap/" +ynh_secure_remove --file="$install_dir/build_transferarchive/" ynh_secure_remove --file="$install_dir/.cache/" ynh_secure_remove --file="$install_dir/go/" ynh_secure_remove --file="$install_dir/.go-version"