diff --git a/.DS_Store b/.DS_Store deleted file mode 100644 index 145651d..0000000 Binary files a/.DS_Store and /dev/null differ diff --git a/README.md b/README.md index 2313185..e53cf30 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in ## Overview -Simple, minimal electronic post-it board +tyto is an extensible and customizable management and organisation tool. **Shipped version:** 3.0.4~ynh2 @@ -28,7 +28,6 @@ Simple, minimal electronic post-it board ## Documentation and resources * Official app website: https://jh3y.github.io/tyto/ -* Official user documentation: https://yunohost.org/apps * Upstream app code repository: https://github.com/jh3y/tyto * YunoHost documentation for this app: https://yunohost.org/app_tyto * Report a bug: https://github.com/YunoHost-Apps/tyto_ynh/issues diff --git a/README_fr.md b/README_fr.md index 008876c..a706d43 100644 --- a/README_fr.md +++ b/README_fr.md @@ -11,7 +11,7 @@ Si vous n'avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour ## Vue d'ensemble -Tableau de post-it électroniques, simple et minimaliste +tyto is an extensible and customizable management and organisation tool. **Version incluse :** 3.0.4~ynh2 @@ -24,7 +24,6 @@ Tableau de post-it électroniques, simple et minimaliste ## Documentations et ressources * Site officiel de l'app : https://jh3y.github.io/tyto/ -* Documentation officielle utilisateur : https://yunohost.org/apps * Dépôt de code officiel de l'app : https://github.com/jh3y/tyto * Documentation YunoHost pour cette app : https://yunohost.org/app_tyto * Signaler un bug : https://github.com/YunoHost-Apps/tyto_ynh/issues diff --git a/check_process b/check_process index 90bfdf3..a545cbf 100644 --- a/check_process +++ b/check_process @@ -11,8 +11,11 @@ setup_private=1 setup_public=1 upgrade=1 + # 3.0.4~ynh2 + upgrade=1 from_commit=db9a6b110a2d2b5f4a7010159d20b3d0cda1b74b backup_restore=1 multi_instance=1 + port_already_use=0 change_url=1 ;;; Options Email=anmol@datamol.org diff --git a/conf/app.src b/conf/app.src index 6e42650..71ccad7 100644 --- a/conf/app.src +++ b/conf/app.src @@ -4,3 +4,4 @@ SOURCE_SUM_PRG=sha256sum SOURCE_FORMAT=zip SOURCE_IN_SUBDIR=true SOURCE_FILENAME= +SOURCE_EXTRACT=true diff --git a/conf/nginx.conf b/conf/nginx.conf index 052c370..508fc0a 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -4,11 +4,6 @@ location __PATH__/ { # Path to source alias __FINALPATH__/ ; - # Force usage of https - if ($scheme = http) { - rewrite ^ https://$server_name$request_uri? permanent; - } - # Include SSOWAT user panel. include conf.d/yunohost_panel.conf.inc; } diff --git a/doc/.DS_Store b/doc/.DS_Store deleted file mode 100644 index b5e9f00..0000000 Binary files a/doc/.DS_Store and /dev/null differ diff --git a/doc/DESCRIPTION.md b/doc/DESCRIPTION.md new file mode 100644 index 0000000..3959d68 --- /dev/null +++ b/doc/DESCRIPTION.md @@ -0,0 +1 @@ +tyto is an extensible and customizable management and organisation tool. \ No newline at end of file diff --git a/manifest.json b/manifest.json index db45cd1..3e9e44d 100644 --- a/manifest.json +++ b/manifest.json @@ -12,7 +12,6 @@ "license": "MIT", "website": "https://jh3y.github.io/tyto/", "demo": "https://jh3y.github.io/tyto/", - "userdoc": "https://yunohost.org/apps", "code": "https://github.com/jh3y/tyto" }, "license": "MIT", @@ -22,18 +21,17 @@ "url": "https://datamol.org" }, "requirements": { - "yunohost": ">= 4.2.4" + "yunohost": ">= 4.3.0" }, "multi_instance": true, "services": [ "nginx" ], "arguments": { - "install" : [ + "install": [ { "name": "domain", - "type": "domain", - "example": "example.com" + "type": "domain" }, { "name": "path", diff --git a/scripts/backup b/scripts/backup index 87e89d3..6201eec 100755 --- a/scripts/backup +++ b/scripts/backup @@ -6,7 +6,7 @@ # IMPORT GENERIC HELPERS #================================================= -#Keep this path for calling _common.sh inside the execution's context of backup and restore scripts +# Keep this path for calling _common.sh inside the execution's context of backup and restore scripts source ../settings/scripts/_common.sh source /usr/share/yunohost/helpers diff --git a/scripts/change_url b/scripts/change_url index b7addbc..211d42d 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -30,7 +30,7 @@ ynh_script_progression --message="Loading installation settings..." final_path=$(ynh_app_setting_get --app=$app --key=final_path) #================================================= -# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP +# BACKUP BEFORE CHANGE URL THEN ACTIVE TRAP #================================================= ynh_script_progression --message="Backing up the app before changing its URL (may take a while)..." @@ -40,7 +40,7 @@ ynh_clean_setup () { # Remove the new domain config file, the remove script won't do it as it doesn't know yet its location. ynh_secure_remove --file="/etc/nginx/conf.d/$new_domain.d/$app.conf" - # restore it if the upgrade fails + # Restore it if the upgrade fails ynh_restore_upgradebackup } # Exit if an error occurs during the execution of the script @@ -71,19 +71,19 @@ ynh_script_progression --message="Updating NGINX web server configuration..." nginx_conf_path=/etc/nginx/conf.d/$old_domain.d/$app.conf -# Change the path in the nginx config file +# Change the path in the NGINX config file if [ $change_path -eq 1 ] then - # Make a backup of the original nginx config file if modified + # Make a backup of the original NGINX config file if modified ynh_backup_if_checksum_is_different --file="$nginx_conf_path" - # Set global variables for nginx helper + # Set global variables for NGINX helper domain="$old_domain" path_url="$new_path" - # Create a dedicated nginx config + # Create a dedicated NGINX config ynh_add_nginx_config fi -# Change the domain for nginx +# Change the domain for NGINX if [ $change_domain -eq 1 ] then # Delete file checksum for the old conf file location diff --git a/scripts/install b/scripts/install index 6096664..c9f5436 100755 --- a/scripts/install +++ b/scripts/install @@ -71,7 +71,7 @@ chown -R $app:www-data "$final_path" #================================================= ynh_script_progression --message="Configuring NGINX web server..." -# Create a dedicated nginx config +# Create a dedicated NGINX config ynh_add_nginx_config #================================================= diff --git a/scripts/remove b/scripts/remove index 781098a..dfa828c 100755 --- a/scripts/remove +++ b/scripts/remove @@ -34,7 +34,7 @@ ynh_secure_remove --file="$final_path" #================================================= ynh_script_progression --message="Removing NGINX web server configuration..." -# Remove the dedicated nginx config +# Remove the dedicated NGINX config ynh_remove_nginx_config #================================================= diff --git a/scripts/restore b/scripts/restore index d8274a7..5d386cf 100755 --- a/scripts/restore +++ b/scripts/restore @@ -6,7 +6,7 @@ # IMPORT GENERIC HELPERS #================================================= -#Keep this path for calling _common.sh inside the execution's context of backup and restore scripts +# Keep this path for calling _common.sh inside the execution's context of backup and restore scripts source ../settings/scripts/_common.sh source /usr/share/yunohost/helpers @@ -20,7 +20,7 @@ ynh_abort_if_errors #================================================= # LOAD SETTINGS #================================================= -ynh_script_progression --message="Loading settings..." +ynh_script_progression --message="Loading installation settings..." app=$YNH_APP_INSTANCE_NAME @@ -33,8 +33,6 @@ final_path=$(ynh_app_setting_get --app=$app --key=final_path) #================================================= ynh_script_progression --message="Validating restoration parameters..." -ynh_webpath_available --domain=$domain --path_url=$path_url \ - || ynh_die --message="Path not available: ${domain}${path_url}" test ! -d $final_path \ || ynh_die --message="There is already a directory: $final_path " @@ -43,7 +41,7 @@ test ! -d $final_path \ #================================================= # RESTORE THE NGINX CONFIGURATION #================================================= -ynh_script_progression --message="Restoring the NGINX configuration..." +ynh_script_progression --message="Restoring the NGINX web server configuration..." ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf" diff --git a/scripts/upgrade b/scripts/upgrade index fd4a9de..1693bc9 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -23,10 +23,25 @@ final_path=$(ynh_app_setting_get --app=$app --key=final_path) #================================================= # CHECK VERSION #================================================= -ynh_script_progression --message="Checking version..." upgrade_type=$(ynh_check_app_version_changed) +#================================================= +# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP +#================================================= +ynh_script_progression --message="Backing up the app before upgrading (may take a while)..." + +# Backup the current version of the app +ynh_backup_before_upgrade +ynh_clean_setup () { + # Restore it if the upgrade fails + ynh_restore_upgradebackup +} +# Exit if an error occurs during the execution of the script +ynh_abort_if_errors + +#================================================= +# STANDARD UPGRADE STEPS #================================================= # ENSURE DOWNWARD COMPATIBILITY #================================================= @@ -45,20 +60,6 @@ if ynh_legacy_permissions_exists; then ynh_app_setting_delete --app=$app --key=is_public fi -#================================================= -# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP -#================================================= -ynh_script_progression --message="Backing up the app before upgrading (may take a while)..." - -# Backup the current version of the app -ynh_backup_before_upgrade -ynh_clean_setup () { - # restore it if the upgrade fails - ynh_restore_upgradebackup -} -# Exit if an error occurs during the execution of the script -ynh_abort_if_errors - #================================================= # CREATE DEDICATED USER #================================================= @@ -67,8 +68,6 @@ ynh_script_progression --message="Making sure dedicated system user exists..." # Create a dedicated user (if not existing) ynh_system_user_create --username=$app --home_dir="$final_path" -#================================================= -# STANDARD UPGRADE STEPS #================================================= # DOWNLOAD, CHECK AND UNPACK SOURCE #================================================= @@ -90,7 +89,7 @@ chown -R $app:www-data "$final_path" #================================================= ynh_script_progression --message="Upgrading NGINX web server configuration..." -# Create a dedicated nginx config +# Create a dedicated NGINX config ynh_add_nginx_config #=================================================