mirror of
https://github.com/YunoHost-Apps/pydio_ynh.git
synced 2024-09-03 20:16:05 +02:00
Merge pull request #17 from YunoHost-Apps/version-2
Cleanup packaging v2, bump to cells v4
This commit is contained in:
commit
fa06d74dc3
15 changed files with 92 additions and 29 deletions
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
*~
|
||||||
|
*.sw[op]
|
|
@ -16,9 +16,10 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in
|
||||||
|
|
||||||
## Overview
|
## Overview
|
||||||
|
|
||||||
File sharing platform
|
Cells V4 now provides secure, cloud-native, scalable, self-hosted, open-core document sharing and collaboration without putting your data at risk.
|
||||||
|
|
||||||
**Shipped version:** 3.0.9~ynh2
|
|
||||||
|
**Shipped version:** 4.3.1~ynh1
|
||||||
|
|
||||||
## Screenshots
|
## Screenshots
|
||||||
|
|
||||||
|
|
|
@ -16,9 +16,10 @@ Si vous n’avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) po
|
||||||
|
|
||||||
## Vue d’ensemble
|
## Vue d’ensemble
|
||||||
|
|
||||||
Plateforme de partage de fichiers
|
Cells V4 offre désormais un partage et une collaboration de documents sécurisés, cloud natifs, évolutifs, auto-hébergés et open-core sans mettre vos données en danger.
|
||||||
|
|
||||||
**Version incluse :** 3.0.9~ynh2
|
|
||||||
|
**Version incluse :** 4.3.1~ynh1
|
||||||
|
|
||||||
## Captures d’écran
|
## Captures d’écran
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
# Basic no-TLS config for the embedded gateway
|
# Basic no-TLS config for the embedded gateway
|
||||||
proxyconfig:
|
proxyconfig:
|
||||||
binds:
|
binds:
|
||||||
- localhost:__PORT__
|
- 127.0.0.1:__PORT__
|
||||||
reverseproxyurl: https://__DOMAIN__
|
reverseproxyurl: https://__DOMAIN__
|
||||||
tlsconfig:
|
tlsconfig:
|
||||||
selfsigned:
|
selfsigned:
|
||||||
|
|
|
@ -1,13 +1,12 @@
|
||||||
location / {
|
location / {
|
||||||
|
proxy_pass https://127.0.0.1:__PORT__;
|
||||||
proxy_pass https://localhost:__PORT__;
|
|
||||||
|
|
||||||
# Include SSOWAT user panel.
|
# Include SSOWAT user panel.
|
||||||
include conf.d/yunohost_panel.conf.inc;
|
include conf.d/yunohost_panel.conf.inc;
|
||||||
}
|
}
|
||||||
|
|
||||||
location /ws/ {
|
location /ws/ {
|
||||||
proxy_pass https://localhost:__PORT__;
|
proxy_pass https://127.0.0.1:__PORT__;
|
||||||
proxy_http_version 1.1;
|
proxy_http_version 1.1;
|
||||||
proxy_set_header Upgrade $http_upgrade;
|
proxy_set_header Upgrade $http_upgrade;
|
||||||
proxy_set_header Connection "Upgrade";
|
proxy_set_header Connection "Upgrade";
|
||||||
|
|
|
@ -8,11 +8,11 @@ AssertFileIsExecutable=__INSTALL_DIR__/cells
|
||||||
[Service]
|
[Service]
|
||||||
User=__APP__
|
User=__APP__
|
||||||
Group=__APP__
|
Group=__APP__
|
||||||
WorkingDirectory=__DATA_DIR__/
|
WorkingDirectory=__INSTALL_DIR__/
|
||||||
PermissionsStartOnly=true
|
PermissionsStartOnly=true
|
||||||
|
|
||||||
AmbientCapabilities=CAP_NET_BIND_SERVICE
|
AmbientCapabilities=CAP_NET_BIND_SERVICE
|
||||||
ExecStart=__INSTALL_DIR__/cells start
|
ExecStart=__INSTALL_DIR__/cells start --grpc_discovery_port __PORT_DISCOVERY_GRPC__ --grpc_port __PORT_GRPC__
|
||||||
Restart=on-failure
|
Restart=on-failure
|
||||||
StandardOutput=journal
|
StandardOutput=journal
|
||||||
StandardError=inherit
|
StandardError=inherit
|
||||||
|
@ -25,7 +25,7 @@ SuccessExitStatus=0
|
||||||
# Add environment variables
|
# Add environment variables
|
||||||
Environment=CELLS_ENABLE_METRICS=false
|
Environment=CELLS_ENABLE_METRICS=false
|
||||||
# Environment=CELLS_WORKING_DIR=__INSTALL_DIR__
|
# Environment=CELLS_WORKING_DIR=__INSTALL_DIR__
|
||||||
# Environment=CELLS_DATA_DIR=__DATA_DIR__
|
Environment=CELLS_DATA_DIR=__DATA_DIR__
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
Cells V4 now provides secure, cloud-native, scalable, self-hosted, open-core document sharing and collaboration without putting your data at risk.
|
1
doc/DESCRIPTION_fr.md
Normal file
1
doc/DESCRIPTION_fr.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
Cells V4 offre désormais un partage et une collaboration de documents sécurisés, cloud natifs, évolutifs, auto-hébergés et open-core sans mettre vos données en danger.
|
|
@ -7,12 +7,12 @@ name = "Pydio"
|
||||||
description.en = "File sharing platform"
|
description.en = "File sharing platform"
|
||||||
description.fr = "Plateforme de partage de fichiers"
|
description.fr = "Plateforme de partage de fichiers"
|
||||||
|
|
||||||
version = "3.0.9~ynh2"
|
version = "4.3.1~ynh1"
|
||||||
|
|
||||||
maintainers = ["julienmalik"]
|
maintainers = ["julienmalik"]
|
||||||
|
|
||||||
[upstream]
|
[upstream]
|
||||||
license = "AGPL-3.0-or-later"
|
license = "AGPL-3.0"
|
||||||
website = "https://pydio.com"
|
website = "https://pydio.com"
|
||||||
admindoc = "https://pydio.com/en/docs"
|
admindoc = "https://pydio.com/en/docs"
|
||||||
code = "https://github.com/pydio/cells"
|
code = "https://github.com/pydio/cells"
|
||||||
|
@ -20,15 +20,16 @@ cpe = "cpe:2.3:a:pydio:cells"
|
||||||
fund = "https://pydio.com/en/pricing"
|
fund = "https://pydio.com/en/pricing"
|
||||||
|
|
||||||
[integration]
|
[integration]
|
||||||
yunohost = ">= 11.1.21"
|
yunohost = ">= 11.2"
|
||||||
architectures = ["amd64"]
|
architectures = ["amd64", "armhf", "arm64"]
|
||||||
multi_instance = true
|
multi_instance = true
|
||||||
|
|
||||||
ldap = false
|
ldap = false
|
||||||
sso = false
|
sso = false
|
||||||
|
|
||||||
disk = "50M"
|
disk = "50M"
|
||||||
ram.build = "500M"
|
ram.build = "700M"
|
||||||
ram.runtime = "500M"
|
ram.runtime = "700M"
|
||||||
|
|
||||||
[install]
|
[install]
|
||||||
[install.domain]
|
[install.domain]
|
||||||
|
@ -45,9 +46,15 @@ ram.runtime = "500M"
|
||||||
type = "password"
|
type = "password"
|
||||||
|
|
||||||
[resources]
|
[resources]
|
||||||
|
|
||||||
|
[resources.sources]
|
||||||
[resources.sources.main]
|
[resources.sources.main]
|
||||||
url = "https://download.pydio.com/pub/cells/release/3.0.9/linux-amd64/pydio-cells-3.0.9-linux-amd64.zip"
|
amd64.url = "https://download.pydio.com/pub/cells/release/4.3.1/linux-amd64/pydio-cells-4.3.1-linux-amd64.zip"
|
||||||
sha256 = "54b1f92dcaa0204f0b2e6ebb1daff0d4911d0b1c60d68acacfeb6290170dd4a8"
|
amd64.sha256 = "966337451cf007ff9294f15db830cda128162604bb44ccd91510fae292c790ee"
|
||||||
|
arm64.url = "https://download.pydio.com/pub/cells/release/4.3.1/linux-arm64/pydio-cells-4.3.1-linux-arm64.zip"
|
||||||
|
arm64.sha256 = "840d9a85e15892b52dd549152bef240015584b82feace9137e8b5b1660e80c43"
|
||||||
|
armhf.url = "https://download.pydio.com/pub/cells/release/4.3.1/linux-arm/pydio-cells-4.3.1-linux-arm.zip"
|
||||||
|
armhf.sha256 = "af200d58f3efd917bf8add2a0e8bfb3bc832780cca470070530afa6bb1caefd0"
|
||||||
in_subdir = false
|
in_subdir = false
|
||||||
|
|
||||||
[resources.system_user]
|
[resources.system_user]
|
||||||
|
@ -66,6 +73,8 @@ ram.runtime = "500M"
|
||||||
|
|
||||||
[resources.ports]
|
[resources.ports]
|
||||||
main.default = 8080
|
main.default = 8080
|
||||||
|
discovery_grpc.default = 50051
|
||||||
|
grpc.default = 50053
|
||||||
|
|
||||||
[resources.apt]
|
[resources.apt]
|
||||||
packages = [
|
packages = [
|
||||||
|
|
41
scripts/change_url
Normal file
41
scripts/change_url
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
#=================================================
|
||||||
|
# GENERIC STARTING
|
||||||
|
#=================================================
|
||||||
|
# IMPORT GENERIC HELPERS
|
||||||
|
#=================================================
|
||||||
|
|
||||||
|
source _common.sh
|
||||||
|
source /usr/share/yunohost/helpers
|
||||||
|
|
||||||
|
#=================================================
|
||||||
|
# STANDARD MODIFICATIONS
|
||||||
|
#=================================================
|
||||||
|
# STOP SYSTEMD SERVICE
|
||||||
|
#=================================================
|
||||||
|
ynh_script_progression --message="Stopping a systemd service..." --weight=1
|
||||||
|
|
||||||
|
ynh_systemd_action --service_name="$app" --action="stop" --log_path="systemd"
|
||||||
|
|
||||||
|
#=================================================
|
||||||
|
# MODIFY URL IN NGINX CONF
|
||||||
|
#=================================================
|
||||||
|
ynh_script_progression --message="Updating NGINX web server configuration..." --weight=1
|
||||||
|
|
||||||
|
ynh_change_url_nginx_config
|
||||||
|
|
||||||
|
#=================================================
|
||||||
|
# GENERIC FINALISATION
|
||||||
|
#=================================================
|
||||||
|
# START SYSTEMD SERVICE
|
||||||
|
#=================================================
|
||||||
|
ynh_script_progression --message="Starting a systemd service..." --weight=1
|
||||||
|
|
||||||
|
ynh_systemd_action --service_name="$app" --action="start" --log_path="systemd"
|
||||||
|
|
||||||
|
#=================================================
|
||||||
|
# END OF SCRIPT
|
||||||
|
#=================================================
|
||||||
|
|
||||||
|
ynh_script_progression --message="Change of URL completed for $app" --last
|
|
@ -32,7 +32,10 @@ ynh_add_config --template="../conf/install-conf.yml" --destination="$install_dir
|
||||||
ynh_delete_file_checksum --file="$install_dir/install-conf.yml"
|
ynh_delete_file_checksum --file="$install_dir/install-conf.yml"
|
||||||
|
|
||||||
pushd "$install_dir"
|
pushd "$install_dir"
|
||||||
ynh_exec_as "$app" ./cells configure --cli --yaml "./install-conf.yml"
|
# See https://pydio.com/fr/docs/cells/v4/working-directories
|
||||||
|
ynh_exec_as "$app" env \
|
||||||
|
CELLS_DATA_DIR="$data_dir" \
|
||||||
|
./cells configure --cli --yaml "./install-conf.yml"
|
||||||
popd
|
popd
|
||||||
ynh_secure_remove --file="$install_dir/install-conf.yml"
|
ynh_secure_remove --file="$install_dir/install-conf.yml"
|
||||||
|
|
||||||
|
@ -54,10 +57,9 @@ yunohost service add "$app" --description="File sharing platform"
|
||||||
ynh_script_progression --message="Starting a systemd service..." --weight=1
|
ynh_script_progression --message="Starting a systemd service..." --weight=1
|
||||||
|
|
||||||
# Start a systemd service
|
# Start a systemd service
|
||||||
ynh_systemd_action --service_name="$app" --action="start" --log_path="systemd" --line_match="Restart done"
|
ynh_systemd_action --service_name="$app" --action="start" --log_path="systemd"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# END OF SCRIPT
|
# END OF SCRIPT
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
ynh_script_progression --message="Installation of $app completed" --last
|
ynh_script_progression --message="Installation of $app completed" --last
|
||||||
|
|
|
@ -26,8 +26,6 @@ ynh_script_progression --message="Restoring the data directory..." --weight=1
|
||||||
|
|
||||||
ynh_restore_file --origin_path="$data_dir" --not_mandatory
|
ynh_restore_file --origin_path="$data_dir" --not_mandatory
|
||||||
|
|
||||||
chmod 750 "$data_dir"
|
|
||||||
chmod -R o-rwx "$data_dir"
|
|
||||||
chown -R "$app:www-data" "$data_dir"
|
chown -R "$app:www-data" "$data_dir"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -55,8 +53,7 @@ yunohost service add "$app" --description="File sharing platform"
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Reloading NGINX web server and $app's service..." --weight=1
|
ynh_script_progression --message="Reloading NGINX web server and $app's service..." --weight=1
|
||||||
|
|
||||||
ynh_systemd_action --service_name="$app" --action="start" --log_path="systemd" --line_match="Restart done"
|
ynh_systemd_action --service_name="$app" --action="start" --log_path="systemd"
|
||||||
|
|
||||||
ynh_systemd_action --service_name=nginx --action=reload
|
ynh_systemd_action --service_name=nginx --action=reload
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
|
@ -16,13 +16,20 @@ source /usr/share/yunohost/helpers
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Stopping a systemd service..." --weight=1
|
ynh_script_progression --message="Stopping a systemd service..." --weight=1
|
||||||
|
|
||||||
ynh_systemd_action --service_name=$app --action="stop"
|
ynh_systemd_action --service_name="$app" --action="stop"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# ENSURE DOWNWARD COMPATIBILITY
|
# ENSURE DOWNWARD COMPATIBILITY
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Ensuring downward compatibility..." --weight=1
|
ynh_script_progression --message="Ensuring downward compatibility..." --weight=1
|
||||||
|
|
||||||
|
# Previous installs might have been listening on local ipv6
|
||||||
|
if ynh_compare_current_package_version --comparison lt "4.3.1~ynh1"; then
|
||||||
|
jq ".defaults.sites[0].Binds[0] = \"127.0.0.1:$port\"" "$install_dir/.config/pydio/cells/pydio.json" \
|
||||||
|
> "$install_dir/_pydio.json"
|
||||||
|
mv "$install_dir/_pydio.json" "$install_dir/.config/pydio/cells/pydio.json"
|
||||||
|
fi
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -54,7 +61,9 @@ yunohost service add "$app" --description="File sharing platform"
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Starting a systemd service..." --weight=1
|
ynh_script_progression --message="Starting a systemd service..." --weight=1
|
||||||
|
|
||||||
ynh_systemd_action --service_name="$app" --action="start" --log_path="systemd" --line_match="Restart done"
|
ynh_systemd_action --service_name="$app" --action="start" --log_path="systemd"
|
||||||
|
|
||||||
|
ynh_exec_warn journalctl -xu "$app.service"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# END OF SCRIPT
|
# END OF SCRIPT
|
||||||
|
|
|
@ -6,4 +6,4 @@ test_format = 1.0
|
||||||
|
|
||||||
exclude = ["change_url"]
|
exclude = ["change_url"]
|
||||||
|
|
||||||
test_upgrade_from.5725c85c09f1d3b76d12a4dc4d367ec911cd0019.name = "Last packaging v2 version"
|
test_upgrade_from.5725c85c09f1d3b76d12a4dc4d367ec911cd0019.name = "Last packaging v1 version"
|
||||||
|
|
Loading…
Add table
Reference in a new issue