From ad05127f2e6291503da95d7cc3cb6614941f411b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 23 Mar 2023 08:54:45 +0100 Subject: [PATCH 01/57] v2 --- conf/.env | 2 +- conf/amd64.src | 6 ---- conf/arm64.src | 6 ---- conf/systemd.service | 6 ++-- manifest.toml | 62 ++++++++++++++++++++++++++++++++++++ scripts/_common.sh | 2 +- scripts/backup | 16 +++++----- scripts/change_url | 76 +++++++++++++++++++++++--------------------- scripts/install | 76 ++++++++++++++++++++++---------------------- scripts/remove | 26 +++++++-------- scripts/restore | 44 ++++++++++++------------- scripts/upgrade | 60 +++++++++++++++++----------------- 12 files changed, 217 insertions(+), 165 deletions(-) delete mode 100644 conf/amd64.src delete mode 100644 conf/arm64.src create mode 100644 manifest.toml diff --git a/conf/.env b/conf/.env index 4ae86f7..d5ad827 100644 --- a/conf/.env +++ b/conf/.env @@ -5,7 +5,7 @@ NODE_ENV=production # Writable path for temporary saving attachments during migration to Meteor-Files # Create directory wekan-uploads -WRITABLE_PATH=__FINALPATH__ +WRITABLE_PATH=__INSTALL_DIR__ # The path to NODEJS __YNH_NODE_LOAD_PATH__ diff --git a/conf/amd64.src b/conf/amd64.src deleted file mode 100644 index 302effe..0000000 --- a/conf/amd64.src +++ /dev/null @@ -1,6 +0,0 @@ -SOURCE_URL=https://github.com/wekan/wekan/releases/download/v6.78/wekan-6.78-amd64.zip -SOURCE_SUM=68a01e20eed464c55a96837f5856a196777d965639e0f5cb8c2239a003bc117f -SOURCE_SUM_PRG=sha256sum -SOURCE_FORMAT=zip -SOURCE_IN_SUBDIR=true -SOURCE_FILENAME= diff --git a/conf/arm64.src b/conf/arm64.src deleted file mode 100644 index dea8886..0000000 --- a/conf/arm64.src +++ /dev/null @@ -1,6 +0,0 @@ -SOURCE_URL=https://github.com/wekan/wekan/releases/download/v6.78/wekan-6.78-arm64.zip -SOURCE_SUM=f85bc8ea5b6d154f8c1aac4f63374f0a30113e11923ec9484d352be8ffb6a5bd -SOURCE_SUM_PRG=sha256sum -SOURCE_FORMAT=zip -SOURCE_IN_SUBDIR=true -SOURCE_FILENAME= diff --git a/conf/systemd.service b/conf/systemd.service index 145be59..15635b5 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -7,9 +7,9 @@ After=network.target __MONGODB_SERVICENAME__.service Type=simple User=__APP__ Group=__APP__ -EnvironmentFile=__FINALPATH__/.env -WorkingDirectory=__FINALPATH__/ -ExecStart=__YNH_NODE__ __FINALPATH__/main.js +EnvironmentFile=__INSTALL_DIR__/.env +WorkingDirectory=__INSTALL_DIR__/ +ExecStart=__YNH_NODE__ __INSTALL_DIR__/main.js Restart=on-failure #StartLimitInterval=86400 #StartLimitBurst=5 diff --git a/manifest.toml b/manifest.toml new file mode 100644 index 0000000..cecfe95 --- /dev/null +++ b/manifest.toml @@ -0,0 +1,62 @@ +packaging_format = 2 + +id = "wekan" +name = "Wekan" +description.en = "Trello-like kanban" +description.fr = "Un kanban similaire à Trello" + +version = "6.78~ynh1" + +maintainers = ["alexAubin", "ljf", "yalh76"] + +[upstream] +license = "MIT" +website = "https://wekan.github.io" +demo = "https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h" +admindoc = "https://github.com/wekan/wekan/wiki" +code = "https://github.com/wekan/wekan" +cpe = "???" # FIXME: optional but recommended if relevant, this is meant to contain the Common Platform Enumeration, which is sort of a standard id for applications defined by the NIST. In particular, Yunohost may use this is in the future to easily track CVE (=security reports) related to apps. The CPE may be obtained by searching here: https://nvd.nist.gov/products/cpe/search. For example, for Nextcloud, the CPE is 'cpe:2.3:a:nextcloud:nextcloud' (no need to include the version number) +fund = "???" # FIXME: optional but recommended (or remove if irrelevant / not applicable). This is meant to be an URL where people can financially support this app, especially when its development is based on volunteers and/or financed by its community. YunoHost may later advertise it in the webadmin. + +[integration] +yunohost = ">= 4.3.0" +architectures = "all" # FIXME: can be replaced by a list of supported archs using the dpkg --print-architecture nomenclature (amd64/i386/armhf/arm64), for example: ["amd64", "i386"] +multi_instance = true +ldap = "?" # FIXME: replace with true, false, or "not_relevant". Not to confuse with the "sso" key : the "ldap" key corresponds to wether or not a user *can* login on the app using its YunoHost credentials. +sso = "?" # FIXME: replace with true, false, or "not_relevant". Not to confuse with the "ldap" key : the "sso" key corresponds to wether or not a user is *automatically logged-in* on the app when logged-in on the YunoHost portal. +disk = "50M" # FIXME: replace with an **estimate** minimum disk requirement. e.g. 20M, 400M, 1G, ... +ram.build = "50M" # FIXME: replace with an **estimate** minimum ram requirement. e.g. 50M, 400M, 1G, ... +ram.runtime = "50M" # FIXME: replace with an **estimate** minimum ram requirement. e.g. 50M, 400M, 1G, ... + +[install] + [install.domain] + # this is a generic question - ask strings are automatically handled by Yunohost's core + type = "domain" + + [install.path] + # this is a generic question - ask strings are automatically handled by Yunohost's core + type = "path" + default = "/wekan" + + [install.init_main_permission] + type = "group" + default = false + + [install.admin] + # this is a generic question - ask strings are automatically handled by Yunohost's core + type = "user" + +[resources] + [resources.sources.main] + arm64.url = "https://github.com/wekan/wekan/releases/download/v6.78/wekan-6.78-arm64.zip" + arm64.sha256 = "f85bc8ea5b6d154f8c1aac4f63374f0a30113e11923ec9484d352be8ffb6a5bd" + amd64.url = "https://github.com/wekan/wekan/releases/download/v6.78/wekan-6.78-amd64.zip" + amd64.sha256 = "68a01e20eed464c55a96837f5856a196777d965639e0f5cb8c2239a003bc117f" + + + [resources.system_user] + + [resources.install_dir] + + [resources.permissions] + main.url = "/" diff --git a/scripts/_common.sh b/scripts/_common.sh index 36ecbcb..87fea33 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -5,7 +5,7 @@ #================================================= # dependencies used by the app -pkg_dependencies="" +#REMOVEME? pkg_dependencies="" nodejs_version="14.19.3" diff --git a/scripts/backup b/scripts/backup index 821ad88..b745e09 100644 --- a/scripts/backup +++ b/scripts/backup @@ -15,22 +15,22 @@ source /usr/share/yunohost/helpers # MANAGE SCRIPT FAILURE #================================================= -ynh_clean_setup () { +#REMOVEME? ynh_clean_setup () { true } # Exit if an error occurs during the execution of the script -ynh_abort_if_errors +#REMOVEME? ynh_abort_if_errors #================================================= # LOAD SETTINGS #================================================= -ynh_print_info --message="Loading installation settings..." +#REMOVEME? ynh_print_info --message="Loading installation settings..." -app=$YNH_APP_INSTANCE_NAME +#REMOVEME? app=$YNH_APP_INSTANCE_NAME -final_path=$(ynh_app_setting_get --app=$app --key=final_path) -domain=$(ynh_app_setting_get --app=$app --key=domain) -db_name=$(ynh_app_setting_get --app=$app --key=db_name) +#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir) +#REMOVEME? domain=$(ynh_app_setting_get --app=$app --key=domain) +#REMOVEME? db_name=$(ynh_app_setting_get --app=$app --key=db_name) #================================================= # DECLARE DATA AND CONF FILES TO BACKUP @@ -41,7 +41,7 @@ ynh_print_info --message="Declaring files to be backed up..." # BACKUP THE APP MAIN DIR #================================================= -ynh_backup --src_path="$final_path" +ynh_backup --src_path="$install_dir" #================================================= # BACKUP THE NGINX CONFIGURATION diff --git a/scripts/change_url b/scripts/change_url index 7fdb43c..9ea2327 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -13,60 +13,60 @@ source /usr/share/yunohost/helpers # RETRIEVE ARGUMENTS #================================================= -old_domain=$YNH_APP_OLD_DOMAIN -old_path=$YNH_APP_OLD_PATH +#REMOVEME? old_domain=$YNH_APP_OLD_DOMAIN +#REMOVEME? old_path=$YNH_APP_OLD_PATH -new_domain=$YNH_APP_NEW_DOMAIN -new_path=$YNH_APP_NEW_PATH +#REMOVEME? new_domain=$YNH_APP_NEW_DOMAIN +#REMOVEME? new_path=$YNH_APP_NEW_PATH -app=$YNH_APP_INSTANCE_NAME +#REMOVEME? app=$YNH_APP_INSTANCE_NAME #================================================= # LOAD SETTINGS #================================================= -ynh_script_progression --message="Loading installation settings..." +#REMOVEME? ynh_script_progression --message="Loading installation settings..." -# Needed for helper "ynh_add_nginx_config" -final_path=$(ynh_app_setting_get --app=$app --key=final_path) +#REMOVEME? # Needed for helper "ynh_add_nginx_config" +#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir) # Add settings here as needed by your application -#db_name=$(ynh_app_setting_get --app=$app --key=db_name) +#REMOVEME? #db_name=$(ynh_app_setting_get --app=$app --key=db_name) #db_user=$db_name -#db_pwd=$(ynh_app_setting_get --app=$app --key=db_pwd) -port=$(ynh_app_setting_get --app=$app --key=port) +#REMOVEME? #db_pwd=$(ynh_app_setting_get --app=$app --key=db_pwd) +#REMOVEME? port=$(ynh_app_setting_get --app=$app --key=port) #================================================= # BACKUP BEFORE CHANGE URL THEN ACTIVE TRAP #================================================= -ynh_script_progression --message="Backing up the app before changing its URL (may take a while)..." +#REMOVEME? ynh_script_progression --message="Backing up the app before changing its URL (may take a while)..." # Backup the current version of the app -ynh_backup_before_upgrade -ynh_clean_setup () { - ynh_clean_check_starting +#REMOVEME? ynh_backup_before_upgrade +#REMOVEME? ynh_clean_setup () { + #REMOVEME? ynh_clean_check_starting # 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" +#REMOVEME? ynh_secure_remove --file="/etc/nginx/conf.d/$new_domain.d/$app.conf" # Restore it if the upgrade fails - ynh_restore_upgradebackup +#REMOVEME? ynh_restore_upgradebackup } # Exit if an error occurs during the execution of the script -ynh_abort_if_errors +#REMOVEME? ynh_abort_if_errors #================================================= # CHECK WHICH PARTS SHOULD BE CHANGED #================================================= -change_domain=0 -if [ "$old_domain" != "$new_domain" ] +#REMOVEME? change_domain=0 +#REMOVEME? if [ "$old_domain" != "$new_domain" ] then - change_domain=1 + #REMOVEME? change_domain=1 fi -change_path=0 -if [ "$old_path" != "$new_path" ] +#REMOVEME? change_path=0 +#REMOVEME? if [ "$old_path" != "$new_path" ] then - change_path=1 + #REMOVEME? change_path=1 fi #================================================= @@ -83,28 +83,30 @@ ynh_systemd_action --service_name=$app --action="stop" --log_path=systemd #================================================= ynh_script_progression --message="Updating NGINX web server configuration..." -nginx_conf_path=/etc/nginx/conf.d/$old_domain.d/$app.conf +ynh_change_url_nginx_config + +#REMOVEME? nginx_conf_path=/etc/nginx/conf.d/$old_domain.d/$app.conf # 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 - ynh_backup_if_checksum_is_different --file="$nginx_conf_path" +#REMOVEME? ynh_backup_if_checksum_is_different --file="$nginx_conf_path" # Set global variables for NGINX helper - domain="$old_domain" - path_url="$new_path" +#REMOVEME? domain="$old_domain" +#REMOVEME? path="$new_path" # Create a dedicated NGINX config - ynh_add_nginx_config +#REMOVEME? ynh_add_nginx_config fi # Change the domain for NGINX if [ $change_domain -eq 1 ] then # Delete file checksum for the old conf file location - ynh_delete_file_checksum --file="$nginx_conf_path" - mv $nginx_conf_path /etc/nginx/conf.d/$new_domain.d/$app.conf +#REMOVEME? ynh_delete_file_checksum --file="$nginx_conf_path" +#REMOVEME? mv $nginx_conf_path /etc/nginx/conf.d/$new_domain.d/$app.conf # Store file checksum for the new config file location - ynh_store_file_checksum --file="/etc/nginx/conf.d/$new_domain.d/$app.conf" +#REMOVEME? ynh_store_file_checksum --file="/etc/nginx/conf.d/$new_domain.d/$app.conf" fi #================================================= @@ -114,9 +116,9 @@ fi #================================================= ynh_script_progression --message="Updating .env configuration..." -ynh_backup_if_checksum_is_different --file="$final_path/.env" -ynh_replace_string --match_string="$old_domain$old_path" --replace_string="$new_domain$new_path" --target_file="$final_path/.env" -ynh_store_file_checksum --file="$final_path/.env" +ynh_backup_if_checksum_is_different --file="$install_dir/.env" +ynh_replace_string --match_string="$old_domain$old_path" --replace_string="$new_domain$new_path" --target_file="$install_dir/.env" +ynh_store_file_checksum --file="$install_dir/.env" #================================================= # GENERIC FINALISATION @@ -135,9 +137,9 @@ fi #================================================= # RELOAD NGINX #================================================= -ynh_script_progression --message="Reloading NGINX web server..." +#REMOVEME? ynh_script_progression --message="Reloading NGINX web server..." -ynh_systemd_action --service_name=nginx --action=reload +#REMOVEME? #REMOVEME? ynh_systemd_action --service_name=nginx --action=reload #================================================= # END OF SCRIPT diff --git a/scripts/install b/scripts/install index be377fc..c68ae7c 100644 --- a/scripts/install +++ b/scripts/install @@ -14,27 +14,27 @@ source /usr/share/yunohost/helpers # MANAGE SCRIPT FAILURE #================================================= -ynh_clean_setup () { +#REMOVEME? ynh_clean_setup () { ynh_clean_check_starting } # Exit if an error occurs during the execution of the script -ynh_abort_if_errors +#REMOVEME? ynh_abort_if_errors #================================================= # RETRIEVE ARGUMENTS FROM THE MANIFEST #================================================= -domain=$YNH_APP_ARG_DOMAIN -path_url=$YNH_APP_ARG_PATH -is_public=$YNH_APP_ARG_IS_PUBLIC -admin=$YNH_APP_ARG_ADMIN +#REMOVEME? domain=$YNH_APP_ARG_DOMAIN +#REMOVEME? path=$YNH_APP_ARG_PATH +#REMOVEME? is_public=$YNH_APP_ARG_IS_PUBLIC +#REMOVEME? admin=$YNH_APP_ARG_ADMIN -app=$YNH_APP_INSTANCE_NAME +#REMOVEME? app=$YNH_APP_INSTANCE_NAME #================================================= # CHECK IF THE APP CAN BE INSTALLED WITH THESE ARGS #================================================= -ynh_script_progression --message="Validating installation parameters..." +#REMOVEME? ynh_script_progression --message="Validating installation parameters..." # Check machine architecture (in particular, we don't support ARM and 32bit machines) if [ $YNH_ARCH == "i386" ] || [ $YNH_ARCH == "armel" ] || [ $YNH_ARCH == "armhf" ] || [ $YNH_ARCH == "aarch64" ] || [ $YNH_ARCH == "arm64" ] @@ -42,37 +42,37 @@ then ynh_die --message="Sorry, but this app can only be installed on a x86, 64 bits machine :(" fi -final_path=/var/www/$app -test ! -e "$final_path" || ynh_die --message="This path already contains a folder" +#REMOVEME? install_dir=/var/www/$app +#REMOVEME? test ! -e "$install_dir" || ynh_die --message="This path already contains a folder" # Register (book) web path -ynh_webpath_register --app=$app --domain=$domain --path_url=$path_url +#REMOVEME? ynh_webpath_register --app=$app --domain=$domain --path=$path #================================================= # STORE SETTINGS FROM MANIFEST #================================================= -ynh_script_progression --message="Storing installation settings..." +#REMOVEME? ynh_script_progression --message="Storing installation settings..." -ynh_app_setting_set --app=$app --key=domain --value=$domain -ynh_app_setting_set --app=$app --key=path --value=$path_url +#REMOVEME? ynh_app_setting_set --app=$app --key=domain --value=$domain +#REMOVEME? ynh_app_setting_set --app=$app --key=path --value=$path #================================================= # STANDARD MODIFICATIONS #================================================= # FIND AND OPEN A PORT #================================================= -ynh_script_progression --message="Finding an available port..." +#REMOVEME? ynh_script_progression --message="Finding an available port..." # Find an available port -port=$(ynh_find_port --port=8095) -ynh_app_setting_set --app=$app --key=port --value=$port +#REMOVEME? port=$(ynh_find_port --port=8095) +#REMOVEME? ynh_app_setting_set --app=$app --key=port --value=$port #================================================= # INSTALL DEPENDENCIES #================================================= -ynh_script_progression --message="Installing dependencies..." +#REMOVEME? ynh_script_progression --message="Installing dependencies..." -ynh_install_app_dependencies $pkg_dependencies +#REMOVEME? ynh_install_app_dependencies $pkg_dependencies ynh_install_nodejs --nodejs_version=$nodejs_version ynh_use_nodejs ynh_install_mongo @@ -80,19 +80,19 @@ ynh_install_mongo #================================================= # CREATE DEDICATED USER #================================================= -ynh_script_progression --message="Configuring system user..." +#REMOVEME? ynh_script_progression --message="Configuring system user..." # Create a system user -ynh_system_user_create --username=$app --home_dir="$final_path" +#REMOVEME? ynh_system_user_create --username=$app --home_dir="$install_dir" #================================================= # CREATE A MONGODB DATABASE #================================================= ynh_script_progression --message="Creating a MongoDB database..." -db_name=$(ynh_sanitize_dbid --db_name=$app) -db_user=$db_name -ynh_app_setting_set --app=$app --key=db_name --value=$db_name +#REMOVEME? db_name=$(ynh_sanitize_dbid --db_name=$app) +#REMOVEME? db_user=$db_name +#REMOVEME? ynh_app_setting_set --app=$app --key=db_name --value=$db_name ynh_mongo_setup_db --db_user=$db_user --db_name=$db_name #================================================= @@ -100,13 +100,13 @@ ynh_mongo_setup_db --db_user=$db_user --db_name=$db_name #================================================= ynh_script_progression --message="Setting up source files..." -ynh_app_setting_set --app=$app --key=final_path --value=$final_path +#REMOVEME? ynh_app_setting_set --app=$app --key=install_dir --value=$install_dir # Download, check integrity, uncompress and patch the source from app.src -ynh_setup_source --dest_dir="$final_path" --source_id="$YNH_ARCH" +ynh_setup_source --dest_dir="$install_dir" -chmod 750 "$final_path" -chmod -R o-rwx "$final_path" -chown -R $app:$app "$final_path" +chmod 750 "$install_dir" +chmod -R o-rwx "$install_dir" +chown -R $app:$app "$install_dir" #================================================= # NGINX CONFIGURATION @@ -125,10 +125,10 @@ ynh_script_progression --message="Adding a config file..." main_domain=$(cat /etc/yunohost/current_host) -ynh_add_config --template=".env" --destination="$final_path/.env" +ynh_add_config --template=".env" --destination="$install_dir/.env" -chmod 400 "$final_path/.env" -chown $app:$app "$final_path/.env" +chmod 400 "$install_dir/.env" +chown $app:$app "$install_dir/.env" #================================================= # SETUP SYSTEMD @@ -162,24 +162,24 @@ fi #================================================= # SETUP SSOWAT #================================================= -ynh_script_progression --message="Configuring permissions..." +#REMOVEME? ynh_script_progression --message="Configuring permissions..." # Make app public if necessary -if [ $is_public -eq 1 ] +#REMOVEME? if [ $is_public -eq 1 ] then # Everyone can access the app. # The "main" permission is automatically created before the install script. - ynh_permission_update --permission="main" --add="visitors" +#REMOVEME? ynh_permission_update --permission="main" --add="visitors" fi -ynh_permission_create --permission="admin" --allowed=$admin +#REMOVEME? ynh_permission_create --permission="admin" --allowed=$admin #================================================= # RELOAD NGINX #================================================= -ynh_script_progression --message="Reloading NGINX web server..." +#REMOVEME? ynh_script_progression --message="Reloading NGINX web server..." -ynh_systemd_action --service_name=nginx --action=reload +#REMOVEME? ynh_systemd_action --service_name=nginx --action=reload #================================================= # END OF SCRIPT diff --git a/scripts/remove b/scripts/remove index 7c94aff..f6726d6 100755 --- a/scripts/remove +++ b/scripts/remove @@ -13,15 +13,15 @@ source /usr/share/yunohost/helpers #================================================= # LOAD SETTINGS #================================================= -ynh_script_progression --message="Loading installation settings..." +#REMOVEME? ynh_script_progression --message="Loading installation settings..." -app=$YNH_APP_INSTANCE_NAME +#REMOVEME? app=$YNH_APP_INSTANCE_NAME -domain=$(ynh_app_setting_get --app=$app --key=domain) -port=$(ynh_app_setting_get --app=$app --key=port) -db_name=$(ynh_app_setting_get --app=$app --key=db_name) -db_user=$db_name -final_path=$(ynh_app_setting_get --app=$app --key=final_path) +#REMOVEME? domain=$(ynh_app_setting_get --app=$app --key=domain) +#REMOVEME? port=$(ynh_app_setting_get --app=$app --key=port) +#REMOVEME? db_name=$(ynh_app_setting_get --app=$app --key=db_name) +#REMOVEME? db_user=$db_name +#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir) #================================================= # STANDARD REMOVE @@ -55,10 +55,10 @@ ynh_mongo_remove_db --db_user=$db_user --db_name=$db_name #================================================= # REMOVE APP MAIN DIR #================================================= -ynh_script_progression --message="Removing app main directory..." +#REMOVEME? ynh_script_progression --message="Removing app main directory..." # Remove the app directory securely -ynh_secure_remove --file="$final_path" +#REMOVEME? ynh_secure_remove --file="$install_dir" #================================================= # REMOVE NGINX CONFIGURATION @@ -71,10 +71,10 @@ ynh_remove_nginx_config #================================================= # REMOVE DEPENDENCIES #================================================= -ynh_script_progression --message="Removing dependencies..." +#REMOVEME? ynh_script_progression --message="Removing dependencies..." # Remove metapackage and its dependencies -ynh_remove_app_dependencies +#REMOVEME? ynh_remove_app_dependencies ynh_remove_nodejs ynh_remove_mongo @@ -83,10 +83,10 @@ ynh_remove_mongo #================================================= # REMOVE DEDICATED USER #================================================= -ynh_script_progression --message="Removing the dedicated system user..." +#REMOVEME? ynh_script_progression --message="Removing the dedicated system user..." # Delete a system user -ynh_system_user_delete --username=$app +#REMOVEME? ynh_system_user_delete --username=$app #================================================= # END OF SCRIPT diff --git a/scripts/restore b/scripts/restore index 3f39656..286da9e 100644 --- a/scripts/restore +++ b/scripts/restore @@ -15,64 +15,64 @@ source /usr/share/yunohost/helpers # MANAGE SCRIPT FAILURE #================================================= -ynh_clean_setup () { +#REMOVEME? ynh_clean_setup () { ynh_clean_check_starting } # Exit if an error occurs during the execution of the script -ynh_abort_if_errors +#REMOVEME? ynh_abort_if_errors #================================================= # LOAD SETTINGS #================================================= -ynh_script_progression --message="Loading installation settings..." +#REMOVEME? ynh_script_progression --message="Loading installation settings..." -app=$YNH_APP_INSTANCE_NAME +#REMOVEME? app=$YNH_APP_INSTANCE_NAME -domain=$(ynh_app_setting_get --app=$app --key=domain) -path_url=$(ynh_app_setting_get --app=$app --key=path) -final_path=$(ynh_app_setting_get --app=$app --key=final_path) -db_name=$(ynh_app_setting_get --app=$app --key=db_name) -db_user=$db_name -mongo_version=$(ynh_app_setting_get --app=$app --key=mongo_version) +#REMOVEME? domain=$(ynh_app_setting_get --app=$app --key=domain) +#REMOVEME? path=$(ynh_app_setting_get --app=$app --key=path) +#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir) +#REMOVEME? db_name=$(ynh_app_setting_get --app=$app --key=db_name) +#REMOVEME? db_user=$db_name +#REMOVEME? mongo_version=$(ynh_app_setting_get --app=$app --key=mongo_version) #================================================= # CHECK IF THE APP CAN BE RESTORED #================================================= -ynh_script_progression --message="Validating restoration parameters..." +#REMOVEME? ynh_script_progression --message="Validating restoration parameters..." -test ! -d $final_path \ - || ynh_die --message="There is already a directory: $final_path " +#REMOVEME? test ! -d $install_dir \ + || ynh_die --message="There is already a directory: $install_dir " #================================================= # STANDARD RESTORATION STEPS #================================================= # RECREATE THE DEDICATED USER #================================================= -ynh_script_progression --message="Recreating the dedicated system user..." +#REMOVEME? ynh_script_progression --message="Recreating the dedicated system user..." # Create the dedicated user (if not existing) -ynh_system_user_create --username=$app --home_dir="$final_path" +#REMOVEME? ynh_system_user_create --username=$app --home_dir="$install_dir" #================================================= # RESTORE THE APP MAIN DIR #================================================= ynh_script_progression --message="Restoring the app main directory..." -ynh_restore_file --origin_path="$final_path" +ynh_restore_file --origin_path="$install_dir" -chmod 750 "$final_path" -chmod -R o-rwx "$final_path" -chown -R $app:$app "$final_path" +chmod 750 "$install_dir" +chmod -R o-rwx "$install_dir" +chown -R $app:$app "$install_dir" #================================================= # SPECIFIC RESTORATION #================================================= # REINSTALL DEPENDENCIES #================================================= -ynh_script_progression --message="Reinstalling dependencies..." +#REMOVEME? ynh_script_progression --message="Reinstalling dependencies..." # Define and install dependencies -ynh_install_app_dependencies $pkg_dependencies +#REMOVEME? ynh_install_app_dependencies $pkg_dependencies ynh_install_nodejs --nodejs_version=$nodejs_version ynh_use_nodejs ynh_install_mongo --mongo_version=$mongo_version @@ -89,7 +89,7 @@ ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf" #================================================= ynh_script_progression --message="Restoring the MongoDB database..." -db_pwd=$(ynh_app_setting_get --app=$app --key=db_pwd) +#REMOVEME? db_pwd=$(ynh_app_setting_get --app=$app --key=db_pwd) ynh_mongo_setup_db --db_user=$db_user --db_name=$db_name --db_pwd=$db_pwd ynh_mongo_restore_db --database="$db_name" < ./dump.bson diff --git a/scripts/upgrade b/scripts/upgrade index add98db..0037fdf 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -13,16 +13,16 @@ source /usr/share/yunohost/helpers #================================================= # LOAD SETTINGS #================================================= -ynh_script_progression --message="Loading installation settings..." +#REMOVEME? ynh_script_progression --message="Loading installation settings..." -app=$YNH_APP_INSTANCE_NAME +#REMOVEME? app=$YNH_APP_INSTANCE_NAME -domain=$(ynh_app_setting_get --app=$app --key=domain) -path_url=$(ynh_app_setting_get --app=$app --key=path) -final_path=$(ynh_app_setting_get --app=$app --key=final_path) -db_name=$(ynh_app_setting_get --app=$app --key=db_name) -port=$(ynh_app_setting_get --app=$app --key=port) -mongo_version=$(ynh_app_setting_get --app=$app --key=mongo_version) +#REMOVEME? domain=$(ynh_app_setting_get --app=$app --key=domain) +#REMOVEME? path=$(ynh_app_setting_get --app=$app --key=path) +#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir) +#REMOVEME? db_name=$(ynh_app_setting_get --app=$app --key=db_name) +#REMOVEME? port=$(ynh_app_setting_get --app=$app --key=port) +#REMOVEME? mongo_version=$(ynh_app_setting_get --app=$app --key=mongo_version) #================================================= # CHECK VERSION @@ -34,17 +34,17 @@ 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)..." +#REMOVEME? 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 () { +#REMOVEME? ynh_backup_before_upgrade +#REMOVEME? ynh_clean_setup () { ynh_clean_check_starting # Restore it if the upgrade fails - ynh_restore_upgradebackup +#REMOVEME? ynh_restore_upgradebackup } # Exit if an error occurs during the execution of the script -ynh_abort_if_errors +#REMOVEME? ynh_abort_if_errors #================================================= # STANDARD UPGRADE STEPS @@ -61,15 +61,15 @@ ynh_systemd_action --service_name=$app --action="stop" --log_path=systemd ynh_script_progression --message="Ensuring downward compatibility..." # Cleaning legacy permissions -if ynh_legacy_permissions_exists; then - ynh_legacy_permissions_delete_all +#REMOVEME? if ynh_legacy_permissions_exists; then +#REMOVEME? ynh_legacy_permissions_delete_all ynh_app_setting_delete --app=$app --key=is_public fi -if ! ynh_permission_exists --permission="admin"; then +#REMOVEME? if ! ynh_permission_exists --permission="admin"; then # Create the required permissions - ynh_permission_create --permission="admin" --allowed=$admin +#REMOVEME? ynh_permission_create --permission="admin" --allowed=$admin fi # If mongo_version doesn't exist, create it @@ -84,10 +84,10 @@ ynh_secure_remove --file="/etc/apt/sources.list.d/mongodb-org-4.4.list" #================================================= # CREATE DEDICATED USER #================================================= -ynh_script_progression --message="Making sure dedicated system user exists..." +#REMOVEME? 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" +#REMOVEME? ynh_system_user_create --username=$app --home_dir="$install_dir" #================================================= # DOWNLOAD, CHECK AND UNPACK SOURCE @@ -98,19 +98,19 @@ then ynh_script_progression --message="Upgrading source files..." # Download, check integrity, uncompress and patch the source from app.src - ynh_setup_source --dest_dir="$final_path" --source_id="$YNH_ARCH" --keep=".env" + ynh_setup_source --dest_dir="$install_dir" --keep=".env" fi -chmod 750 "$final_path" -chmod -R o-rwx "$final_path" -chown -R $app:$app "$final_path" +chmod 750 "$install_dir" +chmod -R o-rwx "$install_dir" +chown -R $app:$app "$install_dir" #================================================= # UPGRADE DEPENDENCIES #================================================= -ynh_script_progression --message="Upgrading dependencies..." +#REMOVEME? ynh_script_progression --message="Upgrading dependencies..." -ynh_install_app_dependencies $pkg_dependencies +#REMOVEME? ynh_install_app_dependencies $pkg_dependencies ynh_install_nodejs --nodejs_version=$nodejs_version ynh_use_nodejs ynh_install_mongo --mongo_version=$mongo_version @@ -132,10 +132,10 @@ ynh_script_progression --message="Updating a configuration file..." main_domain=$(cat /etc/yunohost/current_host) -ynh_add_config --template=".env" --destination="$final_path/.env" +ynh_add_config --template=".env" --destination="$install_dir/.env" -chmod 400 "$final_path/.env" -chown $app:$app "$final_path/.env" +chmod 400 "$install_dir/.env" +chown $app:$app "$install_dir/.env" #================================================= # SETUP SYSTEMD @@ -168,9 +168,9 @@ fi #================================================= # RELOAD NGINX #================================================= -ynh_script_progression --message="Reloading NGINX web server..." +#REMOVEME? ynh_script_progression --message="Reloading NGINX web server..." -ynh_systemd_action --service_name=nginx --action=reload +#REMOVEME? ynh_systemd_action --service_name=nginx --action=reload #================================================= # END OF SCRIPT From 308438d020c2ef95de515f8cb18b45e4f14dce20 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 23 Mar 2023 09:04:14 +0100 Subject: [PATCH 02/57] v2 --- check_process | 57 ---------------- conf/systemd.service | 2 +- doc/{DISCLAIMER.md => ADMIN.md} | 2 - doc/{DISCLAIMER_fr.md => ADMIN_fr.md} | 2 - doc/DESCRIPTION.md | 2 +- doc/DESCRIPTION_fr.md | 2 +- manifest.json | 62 ------------------ manifest.toml | 22 +++---- scripts/_common.sh | 3 - scripts/backup | 21 ------ scripts/change_url | 91 -------------------------- scripts/install | 93 --------------------------- scripts/remove | 32 --------- scripts/restore | 45 ------------- scripts/upgrade | 61 +----------------- tests.toml | 5 ++ 16 files changed, 18 insertions(+), 484 deletions(-) delete mode 100644 check_process rename doc/{DISCLAIMER.md => ADMIN.md} (93%) rename doc/{DISCLAIMER_fr.md => ADMIN_fr.md} (94%) delete mode 100644 manifest.json create mode 100644 tests.toml diff --git a/check_process b/check_process deleted file mode 100644 index 027528c..0000000 --- a/check_process +++ /dev/null @@ -1,57 +0,0 @@ -;; Test complet - ; Manifest - domain="domain.tld" - path="/path" - is_public=1 - admin="john" - ; Checks - pkg_linter=1 - setup_sub_dir=1 - setup_root=1 - setup_nourl=0 - setup_private=1 - setup_public=1 - upgrade=1 - # 3.79~ynh2 - #upgrade=1 from_commit=2843d504bcdb0402939f87ebeeda3417de02a9e4 - # 3.95~ynh1 - #upgrade=1 from_commit=46f4b540cb99090a3fe1d35828094dbbfb34b692 - # 3.95~ynh1 - #upgrade=1 from_commit=3cd252289f4fd138879872658762f4c6ae415cc4 - # 4.09~ynh1 - #upgrade=1 from_commit=c2b4715e8591031f3054cedb1220e7619607bb36 - # 4.43~ynh1 - #upgrade=1 from_commit=2cf63bd4d660eae4526221c1a68efede499e3ee6 - # 4.64~ynh1 - #upgrade=1 from_commit=32fe3a7c342e5f29d7a7534125151723f916de46 - # 4.64~ynh2 - #upgrade=1 from_commit=9e698d094c29fc6ab12ac60cd1d0e68b56bfc953 - # 5.00~ynh1 - #upgrade=1 from_commit=8655e8062d1bc6e90b01b98ca9a0dea15d60119e - # 5.17~ynh1 - #upgrade=1 from_commit=8cdb28eff25b8b431635b87f92f96f8e216ad71f - # 5.35~ynh1 - upgrade=1 from_commit=2e9c8be6b87d5c4cd6693e7b3c0c05cfc7d1ac51 - # 5.93~ynh1 - upgrade=1 from_commit=493a70f7d0e79b3ee92d53976a0cd35fa944b428 - # 6.24~ynh1 - #upgrade=1 from_commit=9a686b180d38329a5b53dcc40c0501961a0144b5 - # 6.26~ynh1 - upgrade=1 from_commit=20ccbbbd80021d71692291bfc8de6d03d32f7a76 - # 6.27.1~ynh1 / Mongo 4.4 - upgrade=1 from_commit=9cac9713c99aabae61074ebdb2b88b1e927a1f1b - # 6.27.1~ynh2 / Mongo 5.0 - upgrade=0 from_commit=1ed17a307bd6a2374a21d3488f17a099107d3984 - # 6.28~ynh1 / Mongo 5.0 - upgrade=0 from_commit=2c93251155dd3ce73bfa03090e914d407cc89d30 - # 6.28~ynh2 / Mongo 5.0 - upgrade=0 from_commit=4bece11c12b5691811e8abb5478093cd932cad94 - # 6.30~ynh1 / Mongo 4.4 ; 5.0 - upgrade=1 from_commit=19d250f0c09d4f8dad4343a86a5d20672853221a - backup_restore=1 - multi_instance=1 - port_already_use=0 - change_url=1 -;;; Options -Email=ljf+ynh-wekan@reflexlibre.net -Notification=down diff --git a/conf/systemd.service b/conf/systemd.service index 15635b5..6c5c220 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -1,5 +1,5 @@ [Unit] -Description=Wekan, task board +Description=Wekan: task board Wants=__MONGODB_SERVICENAME__.service After=network.target __MONGODB_SERVICENAME__.service diff --git a/doc/DISCLAIMER.md b/doc/ADMIN.md similarity index 93% rename from doc/DISCLAIMER.md rename to doc/ADMIN.md index 3d56c28..dc0a1c3 100644 --- a/doc/DISCLAIMER.md +++ b/doc/ADMIN.md @@ -12,5 +12,3 @@ To add an admin account, you can: All others YunhoHost user can access with LDAP authentication. If you have disable ldap authentication, first registered user will be admin, and next ones normal users. If you want other admins too, you can change their permission to admin at Wekan Admin Panel. - -**Private/Public mode:** In private mode, only authorized YunoHost members can access to the Wekan. diff --git a/doc/DISCLAIMER_fr.md b/doc/ADMIN_fr.md similarity index 94% rename from doc/DISCLAIMER_fr.md rename to doc/ADMIN_fr.md index d7c6527..453eefa 100644 --- a/doc/DISCLAIMER_fr.md +++ b/doc/ADMIN_fr.md @@ -12,5 +12,3 @@ Pour ajouter un compte admin, vous pouvez : Tous les autres utilisateurs de YunhoHost peuvent accéder avec l'authentification LDAP. Si vous avez désactivé l'authentification LDAP, le premier utilisateur enregistré sera l'administrateur, et les suivants seront des utilisateurs normaux. Si vous voulez d'autres administrateurs, vous pouvez changer leur permission à admin dans le panneau d'administration de Wekan. - -**Mode privé/public:** En mode privé, seuls les membres autorisés de YunoHost peuvent accéder au Wekan. diff --git a/doc/DESCRIPTION.md b/doc/DESCRIPTION.md index 7620a99..39434ec 100644 --- a/doc/DESCRIPTION.md +++ b/doc/DESCRIPTION.md @@ -1 +1 @@ -WeKan ® is an completely Open Source and Free software collaborative kanban board application with MIT license. +WeKan ® is an completely Open Source and Free software collaborative kanban board application. diff --git a/doc/DESCRIPTION_fr.md b/doc/DESCRIPTION_fr.md index b7d750b..fc3642c 100644 --- a/doc/DESCRIPTION_fr.md +++ b/doc/DESCRIPTION_fr.md @@ -1 +1 @@ -WeKan ® est une application de tableau kanban collaborative entièrement libre et open source avec une licence MIT. +WeKan ® est une application de tableau kanban collaborative entièrement libre et open source. diff --git a/manifest.json b/manifest.json deleted file mode 100644 index 00beeba..0000000 --- a/manifest.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "name": "Wekan", - "id": "wekan", - "packaging_format": 1, - "description": { - "en": "Trello-like kanban", - "fr": "Un kanban similaire à Trello" - }, - "version": "6.78~ynh1", - "url": "https://wekan.github.io", - "upstream": { - "license": "MIT", - "website": "https://wekan.github.io", - "demo": "https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h", - "admindoc": "https://github.com/wekan/wekan/wiki", - "code": "https://github.com/wekan/wekan" - }, - "license": "MIT", - "maintainer": [ - { - "name": "alexAubin", - "email": "alex.aubin@mailoo.org", - "url": "https://github.com/alexAubin/" - }, - { - "name": "ljf" - }, - { - "name": "yalh76" - } - ], - "requirements": { - "yunohost": ">= 4.3.0" - }, - "multi_instance": true, - "services": [ - "nginx" - ], - "arguments": { - "install": [ - { - "name": "domain", - "type": "domain" - }, - { - "name": "path", - "type": "path", - "example": "/wekan", - "default": "/wekan" - }, - { - "name": "is_public", - "type": "boolean", - "default": false - }, - { - "name": "admin", - "type": "user" - } - ] - } -} diff --git a/manifest.toml b/manifest.toml index cecfe95..d0db07a 100644 --- a/manifest.toml +++ b/manifest.toml @@ -3,7 +3,7 @@ packaging_format = 2 id = "wekan" name = "Wekan" description.en = "Trello-like kanban" -description.fr = "Un kanban similaire à Trello" +description.fr = "Kanban similaire à Trello" version = "6.78~ynh1" @@ -15,26 +15,22 @@ website = "https://wekan.github.io" demo = "https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h" admindoc = "https://github.com/wekan/wekan/wiki" code = "https://github.com/wekan/wekan" -cpe = "???" # FIXME: optional but recommended if relevant, this is meant to contain the Common Platform Enumeration, which is sort of a standard id for applications defined by the NIST. In particular, Yunohost may use this is in the future to easily track CVE (=security reports) related to apps. The CPE may be obtained by searching here: https://nvd.nist.gov/products/cpe/search. For example, for Nextcloud, the CPE is 'cpe:2.3:a:nextcloud:nextcloud' (no need to include the version number) -fund = "???" # FIXME: optional but recommended (or remove if irrelevant / not applicable). This is meant to be an URL where people can financially support this app, especially when its development is based on volunteers and/or financed by its community. YunoHost may later advertise it in the webadmin. [integration] -yunohost = ">= 4.3.0" -architectures = "all" # FIXME: can be replaced by a list of supported archs using the dpkg --print-architecture nomenclature (amd64/i386/armhf/arm64), for example: ["amd64", "i386"] +yunohost = ">= 11.1.15" +architectures = ["arm64", "amd64"] multi_instance = true -ldap = "?" # FIXME: replace with true, false, or "not_relevant". Not to confuse with the "sso" key : the "ldap" key corresponds to wether or not a user *can* login on the app using its YunoHost credentials. -sso = "?" # FIXME: replace with true, false, or "not_relevant". Not to confuse with the "ldap" key : the "sso" key corresponds to wether or not a user is *automatically logged-in* on the app when logged-in on the YunoHost portal. -disk = "50M" # FIXME: replace with an **estimate** minimum disk requirement. e.g. 20M, 400M, 1G, ... -ram.build = "50M" # FIXME: replace with an **estimate** minimum ram requirement. e.g. 50M, 400M, 1G, ... -ram.runtime = "50M" # FIXME: replace with an **estimate** minimum ram requirement. e.g. 50M, 400M, 1G, ... +ldap = true +sso = false +disk = "50M" +ram.build = "50M" +ram.runtime = "50M" [install] [install.domain] - # this is a generic question - ask strings are automatically handled by Yunohost's core type = "domain" [install.path] - # this is a generic question - ask strings are automatically handled by Yunohost's core type = "path" default = "/wekan" @@ -43,7 +39,6 @@ ram.runtime = "50M" # FIXME: replace with an **estimate** minimum ram requiremen default = false [install.admin] - # this is a generic question - ask strings are automatically handled by Yunohost's core type = "user" [resources] @@ -53,6 +48,7 @@ ram.runtime = "50M" # FIXME: replace with an **estimate** minimum ram requiremen amd64.url = "https://github.com/wekan/wekan/releases/download/v6.78/wekan-6.78-amd64.zip" amd64.sha256 = "68a01e20eed464c55a96837f5856a196777d965639e0f5cb8c2239a003bc117f" + [resources.ports] [resources.system_user] diff --git a/scripts/_common.sh b/scripts/_common.sh index 87fea33..d8f56f7 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -4,9 +4,6 @@ # COMMON VARIABLES #================================================= -# dependencies used by the app -#REMOVEME? pkg_dependencies="" - nodejs_version="14.19.3" #================================================= diff --git a/scripts/backup b/scripts/backup index b745e09..f8efe62 100644 --- a/scripts/backup +++ b/scripts/backup @@ -11,27 +11,6 @@ source ../settings/scripts/_common.sh source ../settings/scripts/ynh_mongo_db__2 source /usr/share/yunohost/helpers -#================================================= -# MANAGE SCRIPT FAILURE -#================================================= - -#REMOVEME? ynh_clean_setup () { - true -} -# Exit if an error occurs during the execution of the script -#REMOVEME? ynh_abort_if_errors - -#================================================= -# LOAD SETTINGS -#================================================= -#REMOVEME? ynh_print_info --message="Loading installation settings..." - -#REMOVEME? app=$YNH_APP_INSTANCE_NAME - -#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir) -#REMOVEME? domain=$(ynh_app_setting_get --app=$app --key=domain) -#REMOVEME? db_name=$(ynh_app_setting_get --app=$app --key=db_name) - #================================================= # DECLARE DATA AND CONF FILES TO BACKUP #================================================= diff --git a/scripts/change_url b/scripts/change_url index 9ea2327..7acfec8 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -9,66 +9,6 @@ source _common.sh source /usr/share/yunohost/helpers -#================================================= -# RETRIEVE ARGUMENTS -#================================================= - -#REMOVEME? old_domain=$YNH_APP_OLD_DOMAIN -#REMOVEME? old_path=$YNH_APP_OLD_PATH - -#REMOVEME? new_domain=$YNH_APP_NEW_DOMAIN -#REMOVEME? new_path=$YNH_APP_NEW_PATH - -#REMOVEME? app=$YNH_APP_INSTANCE_NAME - -#================================================= -# LOAD SETTINGS -#================================================= -#REMOVEME? ynh_script_progression --message="Loading installation settings..." - -#REMOVEME? # Needed for helper "ynh_add_nginx_config" -#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir) - -# Add settings here as needed by your application -#REMOVEME? #db_name=$(ynh_app_setting_get --app=$app --key=db_name) -#db_user=$db_name -#REMOVEME? #db_pwd=$(ynh_app_setting_get --app=$app --key=db_pwd) -#REMOVEME? port=$(ynh_app_setting_get --app=$app --key=port) - -#================================================= -# BACKUP BEFORE CHANGE URL THEN ACTIVE TRAP -#================================================= -#REMOVEME? ynh_script_progression --message="Backing up the app before changing its URL (may take a while)..." - -# Backup the current version of the app -#REMOVEME? ynh_backup_before_upgrade -#REMOVEME? ynh_clean_setup () { - #REMOVEME? ynh_clean_check_starting - # Remove the new domain config file, the remove script won't do it as it doesn't know yet its location. -#REMOVEME? ynh_secure_remove --file="/etc/nginx/conf.d/$new_domain.d/$app.conf" - - # Restore it if the upgrade fails -#REMOVEME? ynh_restore_upgradebackup -} -# Exit if an error occurs during the execution of the script -#REMOVEME? ynh_abort_if_errors - -#================================================= -# CHECK WHICH PARTS SHOULD BE CHANGED -#================================================= - -#REMOVEME? change_domain=0 -#REMOVEME? if [ "$old_domain" != "$new_domain" ] -then - #REMOVEME? change_domain=1 -fi - -#REMOVEME? change_path=0 -#REMOVEME? if [ "$old_path" != "$new_path" ] -then - #REMOVEME? change_path=1 -fi - #================================================= # STANDARD MODIFICATIONS #================================================= @@ -85,30 +25,6 @@ ynh_script_progression --message="Updating NGINX web server configuration..." ynh_change_url_nginx_config -#REMOVEME? nginx_conf_path=/etc/nginx/conf.d/$old_domain.d/$app.conf - -# 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 -#REMOVEME? ynh_backup_if_checksum_is_different --file="$nginx_conf_path" - # Set global variables for NGINX helper -#REMOVEME? domain="$old_domain" -#REMOVEME? path="$new_path" - # Create a dedicated NGINX config -#REMOVEME? ynh_add_nginx_config -fi - -# Change the domain for NGINX -if [ $change_domain -eq 1 ] -then - # Delete file checksum for the old conf file location -#REMOVEME? ynh_delete_file_checksum --file="$nginx_conf_path" -#REMOVEME? mv $nginx_conf_path /etc/nginx/conf.d/$new_domain.d/$app.conf - # Store file checksum for the new config file location -#REMOVEME? ynh_store_file_checksum --file="/etc/nginx/conf.d/$new_domain.d/$app.conf" -fi - #================================================= # SPECIFIC MODIFICATIONS #================================================= @@ -134,13 +50,6 @@ if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then sleep 60 fi -#================================================= -# RELOAD NGINX -#================================================= -#REMOVEME? ynh_script_progression --message="Reloading NGINX web server..." - -#REMOVEME? #REMOVEME? ynh_systemd_action --service_name=nginx --action=reload - #================================================= # END OF SCRIPT #================================================= diff --git a/scripts/install b/scripts/install index c68ae7c..1741ed2 100644 --- a/scripts/install +++ b/scripts/install @@ -10,89 +10,20 @@ source _common.sh source ynh_mongo_db__2 source /usr/share/yunohost/helpers -#================================================= -# MANAGE SCRIPT FAILURE -#================================================= - -#REMOVEME? ynh_clean_setup () { - ynh_clean_check_starting -} -# Exit if an error occurs during the execution of the script -#REMOVEME? ynh_abort_if_errors - -#================================================= -# RETRIEVE ARGUMENTS FROM THE MANIFEST -#================================================= - -#REMOVEME? domain=$YNH_APP_ARG_DOMAIN -#REMOVEME? path=$YNH_APP_ARG_PATH -#REMOVEME? is_public=$YNH_APP_ARG_IS_PUBLIC -#REMOVEME? admin=$YNH_APP_ARG_ADMIN - -#REMOVEME? app=$YNH_APP_INSTANCE_NAME - -#================================================= -# CHECK IF THE APP CAN BE INSTALLED WITH THESE ARGS -#================================================= -#REMOVEME? ynh_script_progression --message="Validating installation parameters..." - -# Check machine architecture (in particular, we don't support ARM and 32bit machines) -if [ $YNH_ARCH == "i386" ] || [ $YNH_ARCH == "armel" ] || [ $YNH_ARCH == "armhf" ] || [ $YNH_ARCH == "aarch64" ] || [ $YNH_ARCH == "arm64" ] -then - ynh_die --message="Sorry, but this app can only be installed on a x86, 64 bits machine :(" -fi - -#REMOVEME? install_dir=/var/www/$app -#REMOVEME? test ! -e "$install_dir" || ynh_die --message="This path already contains a folder" - -# Register (book) web path -#REMOVEME? ynh_webpath_register --app=$app --domain=$domain --path=$path - -#================================================= -# STORE SETTINGS FROM MANIFEST -#================================================= -#REMOVEME? ynh_script_progression --message="Storing installation settings..." - -#REMOVEME? ynh_app_setting_set --app=$app --key=domain --value=$domain -#REMOVEME? ynh_app_setting_set --app=$app --key=path --value=$path - -#================================================= -# STANDARD MODIFICATIONS -#================================================= -# FIND AND OPEN A PORT -#================================================= -#REMOVEME? ynh_script_progression --message="Finding an available port..." - -# Find an available port -#REMOVEME? port=$(ynh_find_port --port=8095) -#REMOVEME? ynh_app_setting_set --app=$app --key=port --value=$port - #================================================= # INSTALL DEPENDENCIES #================================================= #REMOVEME? ynh_script_progression --message="Installing dependencies..." -#REMOVEME? ynh_install_app_dependencies $pkg_dependencies ynh_install_nodejs --nodejs_version=$nodejs_version ynh_use_nodejs ynh_install_mongo -#================================================= -# CREATE DEDICATED USER -#================================================= -#REMOVEME? ynh_script_progression --message="Configuring system user..." - -# Create a system user -#REMOVEME? ynh_system_user_create --username=$app --home_dir="$install_dir" - #================================================= # CREATE A MONGODB DATABASE #================================================= ynh_script_progression --message="Creating a MongoDB database..." -#REMOVEME? db_name=$(ynh_sanitize_dbid --db_name=$app) -#REMOVEME? db_user=$db_name -#REMOVEME? ynh_app_setting_set --app=$app --key=db_name --value=$db_name ynh_mongo_setup_db --db_user=$db_user --db_name=$db_name #================================================= @@ -100,11 +31,9 @@ ynh_mongo_setup_db --db_user=$db_user --db_name=$db_name #================================================= ynh_script_progression --message="Setting up source files..." -#REMOVEME? ynh_app_setting_set --app=$app --key=install_dir --value=$install_dir # Download, check integrity, uncompress and patch the source from app.src ynh_setup_source --dest_dir="$install_dir" -chmod 750 "$install_dir" chmod -R o-rwx "$install_dir" chown -R $app:$app "$install_dir" @@ -159,28 +88,6 @@ if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then sleep 60 fi -#================================================= -# SETUP SSOWAT -#================================================= -#REMOVEME? ynh_script_progression --message="Configuring permissions..." - -# Make app public if necessary -#REMOVEME? if [ $is_public -eq 1 ] -then - # Everyone can access the app. - # The "main" permission is automatically created before the install script. -#REMOVEME? ynh_permission_update --permission="main" --add="visitors" -fi - -#REMOVEME? ynh_permission_create --permission="admin" --allowed=$admin - -#================================================= -# RELOAD NGINX -#================================================= -#REMOVEME? ynh_script_progression --message="Reloading NGINX web server..." - -#REMOVEME? ynh_systemd_action --service_name=nginx --action=reload - #================================================= # END OF SCRIPT #================================================= diff --git a/scripts/remove b/scripts/remove index f6726d6..0d52701 100755 --- a/scripts/remove +++ b/scripts/remove @@ -10,19 +10,6 @@ source _common.sh source ynh_mongo_db__2 source /usr/share/yunohost/helpers -#================================================= -# LOAD SETTINGS -#================================================= -#REMOVEME? ynh_script_progression --message="Loading installation settings..." - -#REMOVEME? app=$YNH_APP_INSTANCE_NAME - -#REMOVEME? domain=$(ynh_app_setting_get --app=$app --key=domain) -#REMOVEME? port=$(ynh_app_setting_get --app=$app --key=port) -#REMOVEME? db_name=$(ynh_app_setting_get --app=$app --key=db_name) -#REMOVEME? db_user=$db_name -#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir) - #================================================= # STANDARD REMOVE #================================================= @@ -52,14 +39,6 @@ ynh_script_progression --message="Removing the MongoDB database..." # Remove a database if it exists, along with the associated user ynh_mongo_remove_db --db_user=$db_user --db_name=$db_name -#================================================= -# REMOVE APP MAIN DIR -#================================================= -#REMOVEME? ynh_script_progression --message="Removing app main directory..." - -# Remove the app directory securely -#REMOVEME? ynh_secure_remove --file="$install_dir" - #================================================= # REMOVE NGINX CONFIGURATION #================================================= @@ -74,20 +53,9 @@ ynh_remove_nginx_config #REMOVEME? ynh_script_progression --message="Removing dependencies..." # Remove metapackage and its dependencies -#REMOVEME? ynh_remove_app_dependencies ynh_remove_nodejs ynh_remove_mongo -#================================================= -# GENERIC FINALIZATION -#================================================= -# REMOVE DEDICATED USER -#================================================= -#REMOVEME? ynh_script_progression --message="Removing the dedicated system user..." - -# Delete a system user -#REMOVEME? ynh_system_user_delete --username=$app - #================================================= # END OF SCRIPT #================================================= diff --git a/scripts/restore b/scripts/restore index 286da9e..8986ee9 100644 --- a/scripts/restore +++ b/scripts/restore @@ -11,48 +11,6 @@ source ../settings/scripts/_common.sh source ../settings/scripts/ynh_mongo_db__2 source /usr/share/yunohost/helpers -#================================================= -# MANAGE SCRIPT FAILURE -#================================================= - -#REMOVEME? ynh_clean_setup () { - ynh_clean_check_starting -} -# Exit if an error occurs during the execution of the script -#REMOVEME? ynh_abort_if_errors - -#================================================= -# LOAD SETTINGS -#================================================= -#REMOVEME? ynh_script_progression --message="Loading installation settings..." - -#REMOVEME? app=$YNH_APP_INSTANCE_NAME - -#REMOVEME? domain=$(ynh_app_setting_get --app=$app --key=domain) -#REMOVEME? path=$(ynh_app_setting_get --app=$app --key=path) -#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir) -#REMOVEME? db_name=$(ynh_app_setting_get --app=$app --key=db_name) -#REMOVEME? db_user=$db_name -#REMOVEME? mongo_version=$(ynh_app_setting_get --app=$app --key=mongo_version) - -#================================================= -# CHECK IF THE APP CAN BE RESTORED -#================================================= -#REMOVEME? ynh_script_progression --message="Validating restoration parameters..." - -#REMOVEME? test ! -d $install_dir \ - || ynh_die --message="There is already a directory: $install_dir " - -#================================================= -# STANDARD RESTORATION STEPS -#================================================= -# RECREATE THE DEDICATED USER -#================================================= -#REMOVEME? ynh_script_progression --message="Recreating the dedicated system user..." - -# Create the dedicated user (if not existing) -#REMOVEME? ynh_system_user_create --username=$app --home_dir="$install_dir" - #================================================= # RESTORE THE APP MAIN DIR #================================================= @@ -60,7 +18,6 @@ ynh_script_progression --message="Restoring the app main directory..." ynh_restore_file --origin_path="$install_dir" -chmod 750 "$install_dir" chmod -R o-rwx "$install_dir" chown -R $app:$app "$install_dir" @@ -72,7 +29,6 @@ chown -R $app:$app "$install_dir" #REMOVEME? ynh_script_progression --message="Reinstalling dependencies..." # Define and install dependencies -#REMOVEME? ynh_install_app_dependencies $pkg_dependencies ynh_install_nodejs --nodejs_version=$nodejs_version ynh_use_nodejs ynh_install_mongo --mongo_version=$mongo_version @@ -89,7 +45,6 @@ ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf" #================================================= ynh_script_progression --message="Restoring the MongoDB database..." -#REMOVEME? db_pwd=$(ynh_app_setting_get --app=$app --key=db_pwd) ynh_mongo_setup_db --db_user=$db_user --db_name=$db_name --db_pwd=$db_pwd ynh_mongo_restore_db --database="$db_name" < ./dump.bson diff --git a/scripts/upgrade b/scripts/upgrade index 0037fdf..cc41fa4 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -10,42 +10,12 @@ source _common.sh source ynh_mongo_db__2 source /usr/share/yunohost/helpers -#================================================= -# LOAD SETTINGS -#================================================= -#REMOVEME? ynh_script_progression --message="Loading installation settings..." - -#REMOVEME? app=$YNH_APP_INSTANCE_NAME - -#REMOVEME? domain=$(ynh_app_setting_get --app=$app --key=domain) -#REMOVEME? path=$(ynh_app_setting_get --app=$app --key=path) -#REMOVEME? #REMOVEME? install_dir=$(ynh_app_setting_get --app=$app --key=install_dir) -#REMOVEME? db_name=$(ynh_app_setting_get --app=$app --key=db_name) -#REMOVEME? port=$(ynh_app_setting_get --app=$app --key=port) -#REMOVEME? mongo_version=$(ynh_app_setting_get --app=$app --key=mongo_version) - #================================================= # CHECK VERSION #================================================= -ynh_script_progression --message="Checking version..." upgrade_type=$(ynh_check_app_version_changed) -#================================================= -# BACKUP BEFORE UPGRADE THEN ACTIVE TRAP -#================================================= -#REMOVEME? ynh_script_progression --message="Backing up the app before upgrading (may take a while)..." - -# Backup the current version of the app -#REMOVEME? ynh_backup_before_upgrade -#REMOVEME? ynh_clean_setup () { - ynh_clean_check_starting - # Restore it if the upgrade fails -#REMOVEME? ynh_restore_upgradebackup -} -# Exit if an error occurs during the execution of the script -#REMOVEME? ynh_abort_if_errors - #================================================= # STANDARD UPGRADE STEPS #================================================= @@ -60,18 +30,6 @@ ynh_systemd_action --service_name=$app --action="stop" --log_path=systemd #================================================= ynh_script_progression --message="Ensuring downward compatibility..." -# Cleaning legacy permissions -#REMOVEME? if ynh_legacy_permissions_exists; then -#REMOVEME? ynh_legacy_permissions_delete_all - - ynh_app_setting_delete --app=$app --key=is_public -fi - -#REMOVEME? if ! ynh_permission_exists --permission="admin"; then - # Create the required permissions -#REMOVEME? ynh_permission_create --permission="admin" --allowed=$admin -fi - # If mongo_version doesn't exist, create it if [ -z "$mongo_version" ]; then mongo_version="$(mongod --version | grep -oP 'db version v\K.{0,3}')" @@ -81,14 +39,6 @@ fi ynh_secure_remove --file="/etc/apt/sources.list.d/mongodb-org-3.2.list" ynh_secure_remove --file="/etc/apt/sources.list.d/mongodb-org-4.4.list" -#================================================= -# CREATE DEDICATED USER -#================================================= -#REMOVEME? ynh_script_progression --message="Making sure dedicated system user exists..." - -# Create a dedicated user (if not existing) -#REMOVEME? ynh_system_user_create --username=$app --home_dir="$install_dir" - #================================================= # DOWNLOAD, CHECK AND UNPACK SOURCE #================================================= @@ -101,16 +51,14 @@ then ynh_setup_source --dest_dir="$install_dir" --keep=".env" fi -chmod 750 "$install_dir" chmod -R o-rwx "$install_dir" chown -R $app:$app "$install_dir" #================================================= # UPGRADE DEPENDENCIES #================================================= -#REMOVEME? ynh_script_progression --message="Upgrading dependencies..." +ynh_script_progression --message="Upgrading dependencies..." -#REMOVEME? ynh_install_app_dependencies $pkg_dependencies ynh_install_nodejs --nodejs_version=$nodejs_version ynh_use_nodejs ynh_install_mongo --mongo_version=$mongo_version @@ -165,13 +113,6 @@ if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then sleep 60 fi -#================================================= -# RELOAD NGINX -#================================================= -#REMOVEME? ynh_script_progression --message="Reloading NGINX web server..." - -#REMOVEME? ynh_systemd_action --service_name=nginx --action=reload - #================================================= # END OF SCRIPT #================================================= diff --git a/tests.toml b/tests.toml new file mode 100644 index 0000000..d35f112 --- /dev/null +++ b/tests.toml @@ -0,0 +1,5 @@ +test_format = 1.0 + +[default] + + test_upgrade_from.19d250f0.name = "Upgrade from 6.30" From bac8994dca5a50a963e24cac0b989df4ec890952 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Thu, 23 Mar 2023 08:04:20 +0000 Subject: [PATCH 03/57] Auto-update README --- README.md | 21 +-------------------- README_fr.md | 21 +-------------------- 2 files changed, 2 insertions(+), 40 deletions(-) diff --git a/README.md b/README.md index 3fbce30..f8561ec 100644 --- a/README.md +++ b/README.md @@ -16,7 +16,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in ## Overview -WeKan ® is an completely Open Source and Free software collaborative kanban board application with MIT license. +WeKan ® is an completely Open Source and Free software collaborative kanban board application. **Shipped version:** 6.78~ynh1 @@ -27,25 +27,6 @@ WeKan ® is an completely Open Source and Free software collaborative kanban boa ![Screenshot of Wekan](./doc/screenshots/screenshot.jpg) -## Disclaimers / important information - -* There is currently **no SSO integration** though it might be integrated at some point in the app, now that it's supported in Meteor/Wekan. In the meantime, users can create accounts (in fact, they can create infinite number of accounts) manually, and need to login manually specifically in Wekan. -* This app **only works on x86, 64bits architecture**! In particular, it won't work on 32 bit machines or ARM. See the discussion [here](https://github.com/YunoHost-Apps/wekan_ynh/issues/1#issuecomment-401612500). -* YunoHost users with more than one email address can't login to wekan using ldap. For example first YunoHost user has severals email addresses: root@domain; admin@domain; webmaster@domain; postmaster@domain, etc... Workaround: remove all mail aliases of the user you want to connect, connect one time on wekan, recreate the aliases of the YunoHost user. - -## Configuration: -As LDAP authentification is enabled by default, Wekan admins correspond to the permission `Wekan Admin`. The user you choose during installation is member of this group. -To add an admin account, you can: - -- [with the webadmin] go to Users > Groups and permissions > Add the user to the permission `Wekan Admin` -- [or with the command line] `yunohost user permission update wekan.admin -a the_user_to_add` - -All others YunhoHost user can access with LDAP authentication. - -If you have disable ldap authentication, first registered user will be admin, and next ones normal users. If you want other admins too, you can change their permission to admin at Wekan Admin Panel. - -**Private/Public mode:** In private mode, only authorized YunoHost members can access to the Wekan. - ## Documentation and resources * Official app website: diff --git a/README_fr.md b/README_fr.md index 4cb190e..67a5129 100644 --- a/README_fr.md +++ b/README_fr.md @@ -16,7 +16,7 @@ Si vous n’avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) po ## Vue d’ensemble -WeKan ® est une application de tableau kanban collaborative entièrement libre et open source avec une licence MIT. +WeKan ® est une application de tableau kanban collaborative entièrement libre et open source. **Version incluse :** 6.78~ynh1 @@ -27,25 +27,6 @@ WeKan ® est une application de tableau kanban collaborative entièrement libre ![Capture d’écran de Wekan](./doc/screenshots/screenshot.jpg) -## Avertissements / informations importantes - -* Il n'y a actuellement **pas d'intégration SSO**, bien qu'elle puisse être intégrée à un moment donné dans l'application, maintenant qu'elle est supportée par Meteor/Wekan. En attendant, les utilisateurs peuvent créer des comptes (en fait, ils peuvent créer un nombre infini de comptes) manuellement, et doivent se connecter manuellement spécifiquement dans Wekan. -* Cette application **ne fonctionne que sur une architecture x86, 64bits** ! En particulier, elle ne fonctionnera pas sur les machines 32 bits ou ARM. Voir la discussion [ici] (https://github.com/YunoHost-Apps/wekan_ynh/issues/1#issuecomment-401612500). -* Les utilisateurs de YunoHost ayant plus d'une adresse e-mail ne peuvent pas se connecter à wekan en utilisant ldap. Par exemple, le premier utilisateur de YunoHost a plusieurs adresses e-mail : root@domain ; admin@domain ; webmaster@domain ; postmaster@domain, etc.... Solution : supprimez tous les alias de messagerie de l'utilisateur que vous voulez connecter, connectez-vous une fois sur wekan, recréez les alias de l'utilisateur YunoHost. - -## Configuration : -L'authentification LDAP étant activée par défaut, les admins de Wekan correspondent à la permission `Wekan Admin`. L'utilisateur que vous choisissez lors de l'installation est membre de ce groupe. -Pour ajouter un compte admin, vous pouvez : - -- [avec le webadmin] allez dans Utilisateurs > Groupes et permissions > Ajouter l'utilisateur à la permission `Wekan Admin`. -- [ou avec la ligne de commande] `yunohost user permission update wekan.admin -a the_user_to_add`. - -Tous les autres utilisateurs de YunhoHost peuvent accéder avec l'authentification LDAP. - -Si vous avez désactivé l'authentification LDAP, le premier utilisateur enregistré sera l'administrateur, et les suivants seront des utilisateurs normaux. Si vous voulez d'autres administrateurs, vous pouvez changer leur permission à admin dans le panneau d'administration de Wekan. - -**Mode privé/public:** En mode privé, seuls les membres autorisés de YunoHost peuvent accéder au Wekan. - ## Documentations et ressources * Site officiel de l’app : From c59f435c98bf70a6287d73cf93b687dd52b54bc9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 23 Mar 2023 19:00:27 +0100 Subject: [PATCH 04/57] Update install --- scripts/install | 3 +++ 1 file changed, 3 insertions(+) diff --git a/scripts/install b/scripts/install index 1741ed2..0e68d45 100644 --- a/scripts/install +++ b/scripts/install @@ -24,6 +24,9 @@ ynh_install_mongo #================================================= ynh_script_progression --message="Creating a MongoDB database..." +db_name=$(ynh_sanitize_dbid --db_name=$app) +db_user=$db_name +ynh_app_setting_set --app=$app --key=db_name --value=$db_name ynh_mongo_setup_db --db_user=$db_user --db_name=$db_name #================================================= From 76877d1110784c05ee879f434b4a378271b6010d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 23 Mar 2023 21:43:55 +0100 Subject: [PATCH 05/57] Update restore --- scripts/restore | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/restore b/scripts/restore index 8986ee9..55bb9ce 100644 --- a/scripts/restore +++ b/scripts/restore @@ -45,6 +45,8 @@ ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf" #================================================= ynh_script_progression --message="Restoring the MongoDB database..." +db_name=$(ynh_sanitize_dbid --db_name=$app) +db_user=$db_name ynh_mongo_setup_db --db_user=$db_user --db_name=$db_name --db_pwd=$db_pwd ynh_mongo_restore_db --database="$db_name" < ./dump.bson From 0007fabb6e999ee35ba00a8589de297295e04685 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 23 Mar 2023 23:05:29 +0100 Subject: [PATCH 06/57] Update systemd.service --- conf/systemd.service | 3 --- 1 file changed, 3 deletions(-) diff --git a/conf/systemd.service b/conf/systemd.service index 6c5c220..03a30a1 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -16,9 +16,6 @@ Restart=on-failure RestartSec=10 ExecReload=/bin/kill -USR1 $MAINPID RestartSec=10 -StandardOutput=syslog -StandardError=syslog -SyslogIdentifier=__APP__ [Install] WantedBy=multi-user.target From e858b5b5501053672f09c698dd7281560ab168cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 23 Mar 2023 23:08:26 +0100 Subject: [PATCH 07/57] Update systemd.service --- conf/systemd.service | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/conf/systemd.service b/conf/systemd.service index 03a30a1..2b3b3b5 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -11,11 +11,9 @@ EnvironmentFile=__INSTALL_DIR__/.env WorkingDirectory=__INSTALL_DIR__/ ExecStart=__YNH_NODE__ __INSTALL_DIR__/main.js Restart=on-failure -#StartLimitInterval=86400 -#StartLimitBurst=5 -RestartSec=10 -ExecReload=/bin/kill -USR1 $MAINPID -RestartSec=10 +SuccessExitStatus=143 +#RestartSec=10 +#ExecReload=/bin/kill -USR1 $MAINPID [Install] WantedBy=multi-user.target From e4a91eac4148c470dba50d65aa7f6181da4f2776 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 23 Mar 2023 23:10:32 +0100 Subject: [PATCH 08/57] Update install --- scripts/install | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/install b/scripts/install index 0e68d45..b299472 100644 --- a/scripts/install +++ b/scripts/install @@ -13,7 +13,7 @@ source /usr/share/yunohost/helpers #================================================= # INSTALL DEPENDENCIES #================================================= -#REMOVEME? ynh_script_progression --message="Installing dependencies..." +ynh_script_progression --message="Installing dependencies..." ynh_install_nodejs --nodejs_version=$nodejs_version ynh_use_nodejs From 737d34911b30e82cb3efd67a6a93c9512fc1990d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 24 Mar 2023 08:58:15 +0100 Subject: [PATCH 09/57] Update manifest.toml --- manifest.toml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/manifest.toml b/manifest.toml index d0db07a..eb5e259 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Wekan" description.en = "Trello-like kanban" description.fr = "Kanban similaire à Trello" -version = "6.78~ynh1" +version = "6.80~ynh1" maintainers = ["alexAubin", "ljf", "yalh76"] @@ -43,10 +43,10 @@ ram.runtime = "50M" [resources] [resources.sources.main] - arm64.url = "https://github.com/wekan/wekan/releases/download/v6.78/wekan-6.78-arm64.zip" - arm64.sha256 = "f85bc8ea5b6d154f8c1aac4f63374f0a30113e11923ec9484d352be8ffb6a5bd" - amd64.url = "https://github.com/wekan/wekan/releases/download/v6.78/wekan-6.78-amd64.zip" - amd64.sha256 = "68a01e20eed464c55a96837f5856a196777d965639e0f5cb8c2239a003bc117f" + arm64.url = "https://github.com/wekan/wekan/releases/download/v6.80/wekan-6.80-arm64.zip" + arm64.sha256 = "f1b6865a5357391cb79cd9fa8c799542dcf38fea39503343540e9d705f2ea1b1" + amd64.url = "https://github.com/wekan/wekan/releases/download/v6.80/wekan-6.80-amd64.zip" + amd64.sha256 = "e1e627fc290deaa64ba1892cb7afcd34607300e150a9f365e5c39115c399bf16" [resources.ports] From 52426a7faa367f862927ee1571f51fe1c3c707c2 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Fri, 24 Mar 2023 07:58:20 +0000 Subject: [PATCH 10/57] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index f8561ec..dc35602 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in WeKan ® is an completely Open Source and Free software collaborative kanban board application. -**Shipped version:** 6.78~ynh1 +**Shipped version:** 6.80~ynh1 **Demo:** https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h diff --git a/README_fr.md b/README_fr.md index 67a5129..bd359c2 100644 --- a/README_fr.md +++ b/README_fr.md @@ -19,7 +19,7 @@ Si vous n’avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) po WeKan ® est une application de tableau kanban collaborative entièrement libre et open source. -**Version incluse :** 6.78~ynh1 +**Version incluse :** 6.80~ynh1 **Démo :** https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h From c99c672dcd7ecd18b64fca138380162e5ded908d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 24 Mar 2023 08:58:50 +0100 Subject: [PATCH 11/57] Update _common.sh --- scripts/_common.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/_common.sh b/scripts/_common.sh index d8f56f7..cc3a9b2 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -5,6 +5,7 @@ #================================================= nodejs_version="14.19.3" +mongo_version=6.0 #================================================= # PERSONAL HELPERS From 0f3148a95d8bc358047cf9c0f7fe0218dc95569c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 24 Mar 2023 09:01:04 +0100 Subject: [PATCH 12/57] cleaning --- scripts/_common.sh | 349 ++++++++++++++++++++++++++++++++++++++++ scripts/backup | 1 - scripts/install | 1 - scripts/remove | 1 - scripts/restore | 1 - scripts/upgrade | 1 - scripts/ynh_mongo_db__2 | 349 ---------------------------------------- 7 files changed, 349 insertions(+), 354 deletions(-) delete mode 100644 scripts/ynh_mongo_db__2 diff --git a/scripts/_common.sh b/scripts/_common.sh index cc3a9b2..acf8b90 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -15,6 +15,355 @@ mongo_version=6.0 # EXPERIMENTAL HELPERS #================================================= +readonly YNH_DEFAULT_MONGO_VERSION=4.4 +# Declare the actual MongoDB version to use: 4.4 ; 5.0 +# A packager willing to use another version of MongoDB can override the variable into its _common.sh. +YNH_MONGO_VERSION=${YNH_MONGO_VERSION:-$YNH_DEFAULT_MONGO_VERSION} + +# Execute a mongo command +# +# example: ynh_mongo_exec --command='db.getMongo().getDBNames().indexOf("wekan")' +# example: ynh_mongo_exec --command="db.getMongo().getDBNames().indexOf(\"wekan\")" +# +# usage: ynh_mongo_exec [--user=user] [--password=password] [--authenticationdatabase=authenticationdatabase] [--database=database] [--host=host] [--port=port] --command="command" [--eval] +# | arg: -u, --user= - The user name to connect as +# | arg: -p, --password= - The user password +# | arg: -d, --authenticationdatabase= - The authenticationdatabase to connect to +# | arg: -d, --database= - The database to connect to +# | arg: -h, --host= - The host to connect to +# | arg: -P, --port= - The port to connect to +# | arg: -c, --command= - The command to evaluate +# | arg: -e, --eval - Evaluate instead of execute the command. +# +# +ynh_mongo_exec() { + # Declare an array to define the options of this helper. + local legacy_args=upadhPce + local -A args_array=( [u]=user= [p]=password= [a]=authenticationdatabase= [d]=database= [h]=host= [P]=port= [c]=command= [e]=eval ) + local user + local password + local authenticationdatabase + local database + local host + local port + local command + local eval + # Manage arguments with getopts + ynh_handle_getopts_args "$@" + user="${user:-}" + password="${password:-}" + authenticationdatabase="${authenticationdatabase:-}" + database="${database:-}" + host="${host:-}" + port="${port:-}" + eval=${eval:-0} + + # If user is provided + if [ -n "$user" ] + then + user="--username=$user" + + # If password is provided + if [ -n "$password" ] + then + password="--password=$password" + fi + + # If authenticationdatabase is provided + if [ -n "$authenticationdatabase" ] + then + authenticationdatabase="--authenticationDatabase=$authenticationdatabase" + else + authenticationdatabase="--authenticationDatabase=admin" + fi + else + password="" + authenticationdatabase="" + fi + + # If host is provided + if [ -n "$host" ] + then + host="--host=$host" + fi + + # If port is provided + if [ -n "$port" ] + then + port="--port=$port" + fi + + # If eval is not provided + if [ $eval -eq 0 ] + then + # If database is provided + if [ -n "$database" ] + then + database="use $database" + else + database="" + fi + + mongosh --quiet --username $user --password $password --authenticationDatabase $authenticationdatabase --host $host --port $port < ./dump.bson +# +# usage: ynh_mongo_dump_db --database=database +# | arg: -d, --database= - The database name to dump +# | ret: the mongodump output +# +# +ynh_mongo_dump_db() { + # Declare an array to define the options of this helper. + local legacy_args=d + local -A args_array=( [d]=database= ) + local database + # Manage arguments with getopts + ynh_handle_getopts_args "$@" + + mongodump --quiet --db="$database" --archive +} + +# Create a user +# +# [internal] +# +# usage: ynh_mongo_create_user --db_user=user --db_pwd=pwd --db_name=name +# | arg: -u, --db_user= - The user name to create +# | arg: -p, --db_pwd= - The password to identify user by +# | arg: -n, --db_name= - Name of the database to grant privilegies +# +# +ynh_mongo_create_user() { + # Declare an array to define the options of this helper. + local legacy_args=unp + local -A args_array=( [u]=db_user= [n]=db_name= [p]=db_pwd= ) + local db_user + local db_name + local db_pwd + # Manage arguments with getopts + ynh_handle_getopts_args "$@" + + # Create the user and set the user as admin of the db + ynh_mongo_exec --database="$db_name" --command='db.createUser( { user: "'${db_user}'", pwd: "'${db_pwd}'", roles: [ { role: "readWrite", db: "'${db_name}'" } ] } );' + + # Add clustermonitoring rights + ynh_mongo_exec --database="$db_name" --command='db.grantRolesToUser("'${db_user}'",[{ role: "clusterMonitor", db: "admin" }]);' +} + +# Check if a mongo database exists +# +# usage: ynh_mongo_database_exists --database=database +# | arg: -d, --database= - The database for which to check existence +# | exit: Return 1 if the database doesn't exist, 0 otherwise +# +# +ynh_mongo_database_exists() { + # Declare an array to define the options of this helper. + local legacy_args=d + local -A args_array=([d]=database=) + local database + # Manage arguments with getopts + ynh_handle_getopts_args "$@" + + if [ $(ynh_mongo_exec --command='db.getMongo().getDBNames().indexOf("'${database}'")' --eval) -lt 0 ] + then + return 1 + else + return 0 + fi +} + +# Restore a database +# +# example: ynh_mongo_restore_db --database=wekan < ./dump.bson +# +# usage: ynh_mongo_restore_db --database=database +# | arg: -d, --database= - The database name to restore +# +# +ynh_mongo_restore_db() { + # Declare an array to define the options of this helper. + local legacy_args=d + local -A args_array=( [d]=database= ) + local database + # Manage arguments with getopts + ynh_handle_getopts_args "$@" + + mongorestore --quiet --db="$database" --archive +} + +# Drop a user +# +# [internal] +# +# usage: ynh_mongo_drop_user --db_user=user --db_name=name +# | arg: -u, --db_user= - The user to drop +# | arg: -n, --db_name= - Name of the database +# +# +ynh_mongo_drop_user() { + # Declare an array to define the options of this helper. + local legacy_args=un + local -A args_array=( [u]=db_user= [n]=db_name= ) + local db_user + local db_name + # Manage arguments with getopts + ynh_handle_getopts_args "$@" + + ynh_mongo_exec --database="$db_name" --command='db.dropUser("'$db_user'", {w: "majority", wtimeout: 5000})' +} + +# Create a database, an user and its password. Then store the password in the app's config +# +# usage: ynh_mongo_setup_db --db_user=user --db_name=name [--db_pwd=pwd] +# | arg: -u, --db_user= - Owner of the database +# | arg: -n, --db_name= - Name of the database +# | arg: -p, --db_pwd= - Password of the database. If not provided, a password will be generated +# +# After executing this helper, the password of the created database will be available in $db_pwd +# It will also be stored as "mongopwd" into the app settings. +# +# +ynh_mongo_setup_db() { + # Declare an array to define the options of this helper. + local legacy_args=unp + local -A args_array=( [u]=db_user= [n]=db_name= [p]=db_pwd= ) + local db_user + local db_name + db_pwd="" + # Manage arguments with getopts + ynh_handle_getopts_args "$@" + + local new_db_pwd=$(ynh_string_random) # Generate a random password + # If $db_pwd is not provided, use new_db_pwd instead for db_pwd + db_pwd="${db_pwd:-$new_db_pwd}" + + # Create the user and grant access to the database + ynh_mongo_create_user --db_user="$db_user" --db_pwd="$db_pwd" --db_name="$db_name" + + # Store the password in the app's config + ynh_app_setting_set --app=$app --key=db_pwd --value=$db_pwd +} + +# Remove a database if it exists, and the associated user +# +# usage: ynh_mongo_remove_db --db_user=user --db_name=name +# | arg: -u, --db_user= - Owner of the database +# | arg: -n, --db_name= - Name of the database +# +# +ynh_mongo_remove_db() { + # Declare an array to define the options of this helper. + local legacy_args=un + local -A args_array=( [u]=db_user= [n]=db_name= ) + local db_user + local db_name + # Manage arguments with getopts + ynh_handle_getopts_args "$@" + + if ynh_mongo_database_exists --database=$db_name; then # Check if the database exists + ynh_mongo_drop_db --database=$db_name # Remove the database + else + ynh_print_warn --message="Database $db_name not found" + fi + + # Remove mongo user if it exists + ynh_mongo_drop_user --db_user=$db_user --db_name=$db_name +} + +# Install MongoDB and integrate MongoDB service in YunoHost +# +# usage: ynh_install_mongo [--mongo_version=mongo_version] +# | arg: -m, --mongo_version= - Version of MongoDB to install +# +# +ynh_install_mongo() { + # Declare an array to define the options of this helper. + local legacy_args=m + local -A args_array=([m]=mongo_version=) + local mongo_version + # Manage arguments with getopts + ynh_handle_getopts_args "$@" + mongo_version="${mongo_version:-$YNH_MONGO_VERSION}" + + ynh_print_info --message="Installing MongoDB Community Edition..." + ynh_install_extra_app_dependencies --repo="deb http://repo.mongodb.org/apt/debian buster/mongodb-org/$mongo_version main" --package="mongodb-org mongodb-org-server mongodb-org-tools mongodb-mongosh" --key="https://www.mongodb.org/static/pgp/server-$mongo_version.asc" + mongodb_servicename=mongod + + # Make sure MongoDB is started and enabled + systemctl enable $mongodb_servicename --quiet + systemctl daemon-reload --quiet + ynh_systemd_action --service_name=$mongodb_servicename --action=restart --line_match="aiting for connections" --log_path="/var/log/mongodb/$mongodb_servicename.log" + + # Integrate MongoDB service in YunoHost + yunohost service add $mongodb_servicename --description="MongoDB daemon" --log="/var/log/mongodb/$mongodb_servicename.log" + + # Store mongo_version into the config of this app + ynh_app_setting_set --app=$app --key=mongo_version --value=$mongo_version +} + +# Remove MongoDB +# Only remove the MongoDB service integration in YunoHost for now +# if MongoDB package as been removed +# +# usage: ynh_remove_mongo +# +# +ynh_remove_mongo() { + # Only remove the mongodb service if it is not installed. + if ! ynh_package_is_installed --package="mongodb*" + then + ynh_print_info --message="Removing MongoDB service..." + mongodb_servicename=mongod + # Remove the mongodb service + yunohost service remove $mongodb_servicename + ynh_secure_remove --file="/var/lib/mongodb" + ynh_secure_remove --file="/var/log/mongodb" + fi +} + + #================================================= # FUTURE OFFICIAL HELPERS #================================================= diff --git a/scripts/backup b/scripts/backup index f8efe62..00254c7 100644 --- a/scripts/backup +++ b/scripts/backup @@ -8,7 +8,6 @@ # Keep this path for calling _common.sh inside the execution's context of backup and restore scripts source ../settings/scripts/_common.sh -source ../settings/scripts/ynh_mongo_db__2 source /usr/share/yunohost/helpers #================================================= diff --git a/scripts/install b/scripts/install index b299472..6020072 100644 --- a/scripts/install +++ b/scripts/install @@ -7,7 +7,6 @@ #================================================= source _common.sh -source ynh_mongo_db__2 source /usr/share/yunohost/helpers #================================================= diff --git a/scripts/remove b/scripts/remove index 0d52701..44f1ec9 100755 --- a/scripts/remove +++ b/scripts/remove @@ -7,7 +7,6 @@ #================================================= source _common.sh -source ynh_mongo_db__2 source /usr/share/yunohost/helpers #================================================= diff --git a/scripts/restore b/scripts/restore index 55bb9ce..7584ed8 100644 --- a/scripts/restore +++ b/scripts/restore @@ -8,7 +8,6 @@ # Keep this path for calling _common.sh inside the execution's context of backup and restore scripts source ../settings/scripts/_common.sh -source ../settings/scripts/ynh_mongo_db__2 source /usr/share/yunohost/helpers #================================================= diff --git a/scripts/upgrade b/scripts/upgrade index cc41fa4..a09b9db 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -7,7 +7,6 @@ #================================================= source _common.sh -source ynh_mongo_db__2 source /usr/share/yunohost/helpers #================================================= diff --git a/scripts/ynh_mongo_db__2 b/scripts/ynh_mongo_db__2 deleted file mode 100644 index c2ad66a..0000000 --- a/scripts/ynh_mongo_db__2 +++ /dev/null @@ -1,349 +0,0 @@ -#!/bin/bash - -readonly YNH_DEFAULT_MONGO_VERSION=4.4 -# Declare the actual MongoDB version to use: 4.4 ; 5.0 -# A packager willing to use another version of MongoDB can override the variable into its _common.sh. -YNH_MONGO_VERSION=${YNH_MONGO_VERSION:-$YNH_DEFAULT_MONGO_VERSION} - -# Execute a mongo command -# -# example: ynh_mongo_exec --command='db.getMongo().getDBNames().indexOf("wekan")' -# example: ynh_mongo_exec --command="db.getMongo().getDBNames().indexOf(\"wekan\")" -# -# usage: ynh_mongo_exec [--user=user] [--password=password] [--authenticationdatabase=authenticationdatabase] [--database=database] [--host=host] [--port=port] --command="command" [--eval] -# | arg: -u, --user= - The user name to connect as -# | arg: -p, --password= - The user password -# | arg: -d, --authenticationdatabase= - The authenticationdatabase to connect to -# | arg: -d, --database= - The database to connect to -# | arg: -h, --host= - The host to connect to -# | arg: -P, --port= - The port to connect to -# | arg: -c, --command= - The command to evaluate -# | arg: -e, --eval - Evaluate instead of execute the command. -# -# -ynh_mongo_exec() { - # Declare an array to define the options of this helper. - local legacy_args=upadhPce - local -A args_array=( [u]=user= [p]=password= [a]=authenticationdatabase= [d]=database= [h]=host= [P]=port= [c]=command= [e]=eval ) - local user - local password - local authenticationdatabase - local database - local host - local port - local command - local eval - # Manage arguments with getopts - ynh_handle_getopts_args "$@" - user="${user:-}" - password="${password:-}" - authenticationdatabase="${authenticationdatabase:-}" - database="${database:-}" - host="${host:-}" - port="${port:-}" - eval=${eval:-0} - - # If user is provided - if [ -n "$user" ] - then - user="--username=$user" - - # If password is provided - if [ -n "$password" ] - then - password="--password=$password" - fi - - # If authenticationdatabase is provided - if [ -n "$authenticationdatabase" ] - then - authenticationdatabase="--authenticationDatabase=$authenticationdatabase" - else - authenticationdatabase="--authenticationDatabase=admin" - fi - else - password="" - authenticationdatabase="" - fi - - # If host is provided - if [ -n "$host" ] - then - host="--host=$host" - fi - - # If port is provided - if [ -n "$port" ] - then - port="--port=$port" - fi - - # If eval is not provided - if [ $eval -eq 0 ] - then - # If database is provided - if [ -n "$database" ] - then - database="use $database" - else - database="" - fi - - mongosh --quiet --username $user --password $password --authenticationDatabase $authenticationdatabase --host $host --port $port < ./dump.bson -# -# usage: ynh_mongo_dump_db --database=database -# | arg: -d, --database= - The database name to dump -# | ret: the mongodump output -# -# -ynh_mongo_dump_db() { - # Declare an array to define the options of this helper. - local legacy_args=d - local -A args_array=( [d]=database= ) - local database - # Manage arguments with getopts - ynh_handle_getopts_args "$@" - - mongodump --quiet --db="$database" --archive -} - -# Create a user -# -# [internal] -# -# usage: ynh_mongo_create_user --db_user=user --db_pwd=pwd --db_name=name -# | arg: -u, --db_user= - The user name to create -# | arg: -p, --db_pwd= - The password to identify user by -# | arg: -n, --db_name= - Name of the database to grant privilegies -# -# -ynh_mongo_create_user() { - # Declare an array to define the options of this helper. - local legacy_args=unp - local -A args_array=( [u]=db_user= [n]=db_name= [p]=db_pwd= ) - local db_user - local db_name - local db_pwd - # Manage arguments with getopts - ynh_handle_getopts_args "$@" - - # Create the user and set the user as admin of the db - ynh_mongo_exec --database="$db_name" --command='db.createUser( { user: "'${db_user}'", pwd: "'${db_pwd}'", roles: [ { role: "readWrite", db: "'${db_name}'" } ] } );' - - # Add clustermonitoring rights - ynh_mongo_exec --database="$db_name" --command='db.grantRolesToUser("'${db_user}'",[{ role: "clusterMonitor", db: "admin" }]);' -} - -# Check if a mongo database exists -# -# usage: ynh_mongo_database_exists --database=database -# | arg: -d, --database= - The database for which to check existence -# | exit: Return 1 if the database doesn't exist, 0 otherwise -# -# -ynh_mongo_database_exists() { - # Declare an array to define the options of this helper. - local legacy_args=d - local -A args_array=([d]=database=) - local database - # Manage arguments with getopts - ynh_handle_getopts_args "$@" - - if [ $(ynh_mongo_exec --command='db.getMongo().getDBNames().indexOf("'${database}'")' --eval) -lt 0 ] - then - return 1 - else - return 0 - fi -} - -# Restore a database -# -# example: ynh_mongo_restore_db --database=wekan < ./dump.bson -# -# usage: ynh_mongo_restore_db --database=database -# | arg: -d, --database= - The database name to restore -# -# -ynh_mongo_restore_db() { - # Declare an array to define the options of this helper. - local legacy_args=d - local -A args_array=( [d]=database= ) - local database - # Manage arguments with getopts - ynh_handle_getopts_args "$@" - - mongorestore --quiet --db="$database" --archive -} - -# Drop a user -# -# [internal] -# -# usage: ynh_mongo_drop_user --db_user=user --db_name=name -# | arg: -u, --db_user= - The user to drop -# | arg: -n, --db_name= - Name of the database -# -# -ynh_mongo_drop_user() { - # Declare an array to define the options of this helper. - local legacy_args=un - local -A args_array=( [u]=db_user= [n]=db_name= ) - local db_user - local db_name - # Manage arguments with getopts - ynh_handle_getopts_args "$@" - - ynh_mongo_exec --database="$db_name" --command='db.dropUser("'$db_user'", {w: "majority", wtimeout: 5000})' -} - -# Create a database, an user and its password. Then store the password in the app's config -# -# usage: ynh_mongo_setup_db --db_user=user --db_name=name [--db_pwd=pwd] -# | arg: -u, --db_user= - Owner of the database -# | arg: -n, --db_name= - Name of the database -# | arg: -p, --db_pwd= - Password of the database. If not provided, a password will be generated -# -# After executing this helper, the password of the created database will be available in $db_pwd -# It will also be stored as "mongopwd" into the app settings. -# -# -ynh_mongo_setup_db() { - # Declare an array to define the options of this helper. - local legacy_args=unp - local -A args_array=( [u]=db_user= [n]=db_name= [p]=db_pwd= ) - local db_user - local db_name - db_pwd="" - # Manage arguments with getopts - ynh_handle_getopts_args "$@" - - local new_db_pwd=$(ynh_string_random) # Generate a random password - # If $db_pwd is not provided, use new_db_pwd instead for db_pwd - db_pwd="${db_pwd:-$new_db_pwd}" - - # Create the user and grant access to the database - ynh_mongo_create_user --db_user="$db_user" --db_pwd="$db_pwd" --db_name="$db_name" - - # Store the password in the app's config - ynh_app_setting_set --app=$app --key=db_pwd --value=$db_pwd -} - -# Remove a database if it exists, and the associated user -# -# usage: ynh_mongo_remove_db --db_user=user --db_name=name -# | arg: -u, --db_user= - Owner of the database -# | arg: -n, --db_name= - Name of the database -# -# -ynh_mongo_remove_db() { - # Declare an array to define the options of this helper. - local legacy_args=un - local -A args_array=( [u]=db_user= [n]=db_name= ) - local db_user - local db_name - # Manage arguments with getopts - ynh_handle_getopts_args "$@" - - if ynh_mongo_database_exists --database=$db_name; then # Check if the database exists - ynh_mongo_drop_db --database=$db_name # Remove the database - else - ynh_print_warn --message="Database $db_name not found" - fi - - # Remove mongo user if it exists - ynh_mongo_drop_user --db_user=$db_user --db_name=$db_name -} - -# Install MongoDB and integrate MongoDB service in YunoHost -# -# usage: ynh_install_mongo [--mongo_version=mongo_version] -# | arg: -m, --mongo_version= - Version of MongoDB to install -# -# -ynh_install_mongo() { - # Declare an array to define the options of this helper. - local legacy_args=m - local -A args_array=([m]=mongo_version=) - local mongo_version - # Manage arguments with getopts - ynh_handle_getopts_args "$@" - mongo_version="${mongo_version:-$YNH_MONGO_VERSION}" - - ynh_print_info --message="Installing MongoDB Community Edition..." - ynh_install_extra_app_dependencies --repo="deb http://repo.mongodb.org/apt/debian buster/mongodb-org/$mongo_version main" --package="mongodb-org mongodb-org-server mongodb-org-tools mongodb-mongosh" --key="https://www.mongodb.org/static/pgp/server-$mongo_version.asc" - mongodb_servicename=mongod - - # Make sure MongoDB is started and enabled - systemctl enable $mongodb_servicename --quiet - systemctl daemon-reload --quiet - ynh_systemd_action --service_name=$mongodb_servicename --action=restart --line_match="aiting for connections" --log_path="/var/log/mongodb/$mongodb_servicename.log" - - # Integrate MongoDB service in YunoHost - yunohost service add $mongodb_servicename --description="MongoDB daemon" --log="/var/log/mongodb/$mongodb_servicename.log" - - # Store mongo_version into the config of this app - ynh_app_setting_set --app=$app --key=mongo_version --value=$mongo_version -} - -# Remove MongoDB -# Only remove the MongoDB service integration in YunoHost for now -# if MongoDB package as been removed -# -# usage: ynh_remove_mongo -# -# -ynh_remove_mongo() { - # Only remove the mongodb service if it is not installed. - if ! ynh_package_is_installed --package="mongodb*" - then - ynh_print_info --message="Removing MongoDB service..." - mongodb_servicename=mongod - # Remove the mongodb service - yunohost service remove $mongodb_servicename - ynh_secure_remove --file="/var/lib/mongodb" - ynh_secure_remove --file="/var/log/mongodb" - fi -} From 6326deb26b044e987db2a5eb1e58d850ed2e1ba5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 24 Mar 2023 09:03:18 +0100 Subject: [PATCH 13/57] Update manifest.toml --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index eb5e259..751fd05 100644 --- a/manifest.toml +++ b/manifest.toml @@ -36,7 +36,7 @@ ram.runtime = "50M" [install.init_main_permission] type = "group" - default = false + default = "visitors" [install.admin] type = "user" From 6cb8aeef2b498bb2213235359c7af1ddcd1d9fb6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 24 Mar 2023 13:32:45 +0100 Subject: [PATCH 14/57] Update restore --- scripts/restore | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/scripts/restore b/scripts/restore index 7584ed8..9da1999 100644 --- a/scripts/restore +++ b/scripts/restore @@ -10,6 +10,14 @@ source ../settings/scripts/_common.sh source /usr/share/yunohost/helpers +#================================================= +# LOAD SETTINGS +#================================================= +ynh_script_progression --message="Loading installation settings..." --weight=1 + +db_name=$(ynh_app_setting_get --app=$app --key=db_name) +db_user=$db_name + #================================================= # RESTORE THE APP MAIN DIR #================================================= @@ -44,9 +52,6 @@ ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf" #================================================= ynh_script_progression --message="Restoring the MongoDB database..." -db_name=$(ynh_sanitize_dbid --db_name=$app) -db_user=$db_name -ynh_mongo_setup_db --db_user=$db_user --db_name=$db_name --db_pwd=$db_pwd ynh_mongo_restore_db --database="$db_name" < ./dump.bson #================================================= From bcce89f897c37c631e3c2be0c2f8409eb026534c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 24 Mar 2023 13:33:46 +0100 Subject: [PATCH 15/57] Update remove --- scripts/remove | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/scripts/remove b/scripts/remove index 44f1ec9..9b4df5a 100755 --- a/scripts/remove +++ b/scripts/remove @@ -9,6 +9,14 @@ source _common.sh source /usr/share/yunohost/helpers +#================================================= +# LOAD SETTINGS +#================================================= +ynh_script_progression --message="Loading installation settings..." --weight=1 + +db_name=$(ynh_app_setting_get --app=$app --key=db_name) +db_user=$db_name + #================================================= # STANDARD REMOVE #================================================= From cf573ff10a95e5678464e35b5657cf545be59445 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 25 Mar 2023 20:58:01 +0100 Subject: [PATCH 16/57] fix --- scripts/restore | 8 -------- 1 file changed, 8 deletions(-) diff --git a/scripts/restore b/scripts/restore index 9da1999..81efeb8 100644 --- a/scripts/restore +++ b/scripts/restore @@ -10,14 +10,6 @@ source ../settings/scripts/_common.sh source /usr/share/yunohost/helpers -#================================================= -# LOAD SETTINGS -#================================================= -ynh_script_progression --message="Loading installation settings..." --weight=1 - -db_name=$(ynh_app_setting_get --app=$app --key=db_name) -db_user=$db_name - #================================================= # RESTORE THE APP MAIN DIR #================================================= From c2f6945ae32232932375773d58f81979757f811b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 3 Apr 2023 20:57:04 +0200 Subject: [PATCH 17/57] Update manifest.toml --- manifest.toml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index 751fd05..5def91e 100644 --- a/manifest.toml +++ b/manifest.toml @@ -17,7 +17,7 @@ admindoc = "https://github.com/wekan/wekan/wiki" code = "https://github.com/wekan/wekan" [integration] -yunohost = ">= 11.1.15" +yunohost = ">= 11.1.16" architectures = ["arm64", "amd64"] multi_instance = true ldap = true @@ -47,6 +47,9 @@ ram.runtime = "50M" arm64.sha256 = "f1b6865a5357391cb79cd9fa8c799542dcf38fea39503343540e9d705f2ea1b1" amd64.url = "https://github.com/wekan/wekan/releases/download/v6.80/wekan-6.80-amd64.zip" amd64.sha256 = "e1e627fc290deaa64ba1892cb7afcd34607300e150a9f365e5c39115c399bf16" + autoupdate.strategy = "latest_github_release" + autoupdate.asset.amd64 = "*-amd64.zip" + autoupdate.asset.arm64 = "*-arm64.zip" [resources.ports] From e6b4974df79888de449f6ec659bb52b3da788b51 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 12 Jun 2023 15:38:46 +0200 Subject: [PATCH 18/57] cleaning --- doc/DESCRIPTION.md | 2 +- doc/DESCRIPTION_fr.md | 2 +- manifest.toml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/DESCRIPTION.md b/doc/DESCRIPTION.md index 39434ec..45d1b5d 100644 --- a/doc/DESCRIPTION.md +++ b/doc/DESCRIPTION.md @@ -1 +1 @@ -WeKan ® is an completely Open Source and Free software collaborative kanban board application. +WeKan® is an completely Open Source and Free software collaborative kanban board application. diff --git a/doc/DESCRIPTION_fr.md b/doc/DESCRIPTION_fr.md index fc3642c..90dbc73 100644 --- a/doc/DESCRIPTION_fr.md +++ b/doc/DESCRIPTION_fr.md @@ -1 +1 @@ -WeKan ® est une application de tableau kanban collaborative entièrement libre et open source. +WeKan® est une application de tableau kanban collaborative entièrement libre et open source. diff --git a/manifest.toml b/manifest.toml index 5def91e..bb11031 100644 --- a/manifest.toml +++ b/manifest.toml @@ -17,7 +17,7 @@ admindoc = "https://github.com/wekan/wekan/wiki" code = "https://github.com/wekan/wekan" [integration] -yunohost = ">= 11.1.16" +yunohost = ">= 11.1.20" architectures = ["arm64", "amd64"] multi_instance = true ldap = true From 30aee950bf18e07d72d6e57c37ca6b48a569017b Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Mon, 12 Jun 2023 13:38:51 +0000 Subject: [PATCH 19/57] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index dc35602..2834c9b 100644 --- a/README.md +++ b/README.md @@ -16,7 +16,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in ## Overview -WeKan ® is an completely Open Source and Free software collaborative kanban board application. +WeKan® is an completely Open Source and Free software collaborative kanban board application. **Shipped version:** 6.80~ynh1 diff --git a/README_fr.md b/README_fr.md index bd359c2..ed00350 100644 --- a/README_fr.md +++ b/README_fr.md @@ -16,7 +16,7 @@ Si vous n’avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) po ## Vue d’ensemble -WeKan ® est une application de tableau kanban collaborative entièrement libre et open source. +WeKan® est une application de tableau kanban collaborative entièrement libre et open source. **Version incluse :** 6.80~ynh1 From d50f45258c91a7abdad0ba4ee13301d3dde7bfc0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 12 Jun 2023 15:41:11 +0200 Subject: [PATCH 20/57] Update manifest.toml --- manifest.toml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/manifest.toml b/manifest.toml index bb11031..c215b18 100644 --- a/manifest.toml +++ b/manifest.toml @@ -43,10 +43,10 @@ ram.runtime = "50M" [resources] [resources.sources.main] - arm64.url = "https://github.com/wekan/wekan/releases/download/v6.80/wekan-6.80-arm64.zip" - arm64.sha256 = "f1b6865a5357391cb79cd9fa8c799542dcf38fea39503343540e9d705f2ea1b1" - amd64.url = "https://github.com/wekan/wekan/releases/download/v6.80/wekan-6.80-amd64.zip" - amd64.sha256 = "e1e627fc290deaa64ba1892cb7afcd34607300e150a9f365e5c39115c399bf16" + arm64.url = "https://github.com/wekan/wekan/releases/download/v6.97/wekan-6.97-arm64.zip" + arm64.sha256 = "3c60fadf67cee852da3e453f32e9548b5ba4f9bd2bdba7e4f60a9f3c4998b08a" + amd64.url = "https://github.com/wekan/wekan/releases/download/v6.97/wekan-6.97-amd64.zip" + amd64.sha256 = "b2637a2a1545a35ac622651aa9d58b58f295ada66cfe9863602aafbfcac90dcc" autoupdate.strategy = "latest_github_release" autoupdate.asset.amd64 = "*-amd64.zip" autoupdate.asset.arm64 = "*-arm64.zip" From c567420ba05d77fa786a552798cad0c43a05abec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 12 Jun 2023 15:41:24 +0200 Subject: [PATCH 21/57] Update manifest.toml --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index c215b18..4a18a63 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Wekan" description.en = "Trello-like kanban" description.fr = "Kanban similaire à Trello" -version = "6.80~ynh1" +version = "6.97~ynh1" maintainers = ["alexAubin", "ljf", "yalh76"] From e243e7c15f85836f2d29cfce7399703d5fc7d49d Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Mon, 12 Jun 2023 13:41:29 +0000 Subject: [PATCH 22/57] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 2834c9b..38c2061 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in WeKan® is an completely Open Source and Free software collaborative kanban board application. -**Shipped version:** 6.80~ynh1 +**Shipped version:** 6.97~ynh1 **Demo:** https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h diff --git a/README_fr.md b/README_fr.md index ed00350..5e1eb5f 100644 --- a/README_fr.md +++ b/README_fr.md @@ -19,7 +19,7 @@ Si vous n’avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) po WeKan® est une application de tableau kanban collaborative entièrement libre et open source. -**Version incluse :** 6.80~ynh1 +**Version incluse :** 6.97~ynh1 **Démo :** https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h From 4e58b4c443dd545cebcd490f4a6e69099ee42eca Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Fri, 14 Jul 2023 09:07:30 +0200 Subject: [PATCH 23/57] cleaning --- .github/workflows/updater.sh | 133 ---------------------------------- .github/workflows/updater.yml | 50 ------------- manifest.toml | 2 +- 3 files changed, 1 insertion(+), 184 deletions(-) delete mode 100644 .github/workflows/updater.sh delete mode 100644 .github/workflows/updater.yml diff --git a/.github/workflows/updater.sh b/.github/workflows/updater.sh deleted file mode 100644 index defbac9..0000000 --- a/.github/workflows/updater.sh +++ /dev/null @@ -1,133 +0,0 @@ -#!/bin/bash - -#================================================= -# PACKAGE UPDATING HELPER -#================================================= - -# This script is meant to be run by GitHub Actions -# The YunoHost-Apps organisation offers a template Action to run this script periodically -# Since each app is different, maintainers can adapt its contents so as to perform -# automatic actions when a new upstream release is detected. - -#================================================= -# FETCHING LATEST RELEASE AND ITS ASSETS -#================================================= - -# Fetching information -current_version=$(cat manifest.json | jq -j '.version|split("~")[0]') -repo=$(cat manifest.json | jq -j '.upstream.code|split("https://github.com/")[1]') -# Some jq magic is needed, because the latest upstream release is not always the latest version (e.g. security patches for older versions) -version=$(curl --silent "https://api.github.com/repos/$repo/releases" | jq -r '.[] | select( .prerelease != true ) | .tag_name' | sort -V | tail -1) -assets=($(curl --silent "https://api.github.com/repos/$repo/releases" | jq -r '[ .[] | select(.tag_name=="'$version'").assets[].browser_download_url ] | join(" ") | @sh' | tr -d "'")) - -# Later down the script, we assume the version has only digits and dots -# Sometimes the release name starts with a "v", so let's filter it out. -# You may need more tweaks here if the upstream repository has different naming conventions. -if [[ ${version:0:1} == "v" || ${version:0:1} == "V" ]]; then - version=${version:1} -fi - -# Setting up the environment variables -echo "Current version: $current_version" -echo "Latest release from upstream: $version" -echo "VERSION=$version" >> $GITHUB_ENV -echo "REPO=$repo" >> $GITHUB_ENV -# For the time being, let's assume the script will fail -echo "PROCEED=false" >> $GITHUB_ENV - -# Proceed only if the retrieved version is greater than the current one -if ! dpkg --compare-versions "$current_version" "lt" "$version" ; then - echo "::warning ::No new version available" - exit 0 -# Proceed only if a PR for this new version does not already exist -elif git ls-remote -q --exit-code --heads https://github.com/$GITHUB_REPOSITORY.git ci-auto-update-v$version ; then - echo "::warning ::A branch already exists for this update" - exit 0 -fi - -# Each release can hold multiple assets (e.g. binaries for different architectures, source code, etc.) -echo "${#assets[@]} available asset(s)" - -#================================================= -# UPDATE SOURCE FILES -#================================================= - -# Here we use the $assets variable to get the resources published in the upstream release. -# Here is an example for Grav, it has to be adapted in accordance with how the upstream releases look like. - -# Let's loop over the array of assets URLs -for asset_url in ${assets[@]}; do - - echo "Handling asset at $asset_url" - - # Assign the asset to a source file in conf/ directory - # Here we base the source file name upon a unique keyword in the assets url (admin vs. update) - # Leave $src empty to ignore the asset - case $asset_url in - *"amd64"*) - src="amd64" - ;; - *"arm64"*) - src="arm64" - ;; - *) - src="" - ;; - esac - - # If $src is not empty, let's process the asset - if [ ! -z "$src" ]; then - # Create the temporary directory - tempdir="$(mktemp -d)" - - # Download sources and calculate checksum - filename=${asset_url##*/} - curl --silent -4 -L $asset_url -o "$tempdir/$filename" - checksum=$(sha256sum "$tempdir/$filename" | head -c 64) - - # Delete temporary directory - rm -rf $tempdir - - # Get extension - if [[ $filename == *.tar.gz ]]; then - extension=tar.gz - else - extension=${filename##*.} - fi - - # Rewrite source file - cat < conf/$src.src -SOURCE_URL=$asset_url -SOURCE_SUM=$checksum -SOURCE_SUM_PRG=sha256sum -SOURCE_FORMAT=$extension -SOURCE_IN_SUBDIR=true -SOURCE_FILENAME= -EOT - echo "... conf/$src.src updated" - - else - echo "... asset ignored" - fi - -done - -#================================================= -# SPECIFIC UPDATE STEPS -#================================================= - -# Any action on the app's source code can be done. -# The GitHub Action workflow takes care of committing all changes after this script ends. - -#================================================= -# GENERIC FINALIZATION -#================================================= - -# Replace new version in manifest -echo "$(jq -s --indent 4 ".[] | .version = \"$version~ynh1\"" manifest.json)" > manifest.json - -# No need to update the README, yunohost-bot takes care of it - -# The Action will proceed only if the PROCEED environment variable is set to true -echo "PROCEED=true" >> $GITHUB_ENV -exit 0 diff --git a/.github/workflows/updater.yml b/.github/workflows/updater.yml deleted file mode 100644 index 08ec1b3..0000000 --- a/.github/workflows/updater.yml +++ /dev/null @@ -1,50 +0,0 @@ -# This workflow allows GitHub Actions to automagically update your app whenever a new upstream release is detected. -# You need to enable Actions in your repository settings, and fetch this Action from the YunoHost-Apps organization. -# This file should be enough by itself, but feel free to tune it to your needs. -# It calls updater.sh, which is where you should put the app-specific update steps. -name: Check for new upstream releases -on: - # Allow to manually trigger the workflow - workflow_dispatch: - # Run it every day at 6:00 UTC - schedule: - - cron: '0 6 * * *' -jobs: - updater: - runs-on: ubuntu-latest - steps: - - name: Fetch the source code - uses: actions/checkout@v3 - with: - token: ${{ secrets.GITHUB_TOKEN }} - - name: Run the updater script - id: run_updater - run: | - # Setting up Git user - git config --global user.name 'yunohost-bot' - git config --global user.email 'yunohost-bot@users.noreply.github.com' - # Run the updater script - /bin/bash .github/workflows/updater.sh - - name: Commit changes - id: commit - if: ${{ env.PROCEED == 'true' }} - run: | - git commit -am "Upgrade to v$VERSION" - - name: Create Pull Request - id: cpr - if: ${{ env.PROCEED == 'true' }} - uses: peter-evans/create-pull-request@v4 - with: - token: ${{ secrets.GITHUB_TOKEN }} - commit-message: Update to version ${{ env.VERSION }} - committer: 'yunohost-bot ' - author: 'yunohost-bot ' - signoff: false - base: testing - branch: ci-auto-update-v${{ env.VERSION }} - delete-branch: true - title: 'Upgrade to version ${{ env.VERSION }}' - body: | - Upgrade to v${{ env.VERSION }} - draft: false - diff --git a/manifest.toml b/manifest.toml index 4a18a63..4672acb 100644 --- a/manifest.toml +++ b/manifest.toml @@ -17,7 +17,7 @@ admindoc = "https://github.com/wekan/wekan/wiki" code = "https://github.com/wekan/wekan" [integration] -yunohost = ">= 11.1.20" +yunohost = ">= 11.1.21" architectures = ["arm64", "amd64"] multi_instance = true ldap = true From f43fe58a2474a7731ed247996769255440e3d64b Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Thu, 10 Aug 2023 05:47:46 +0000 Subject: [PATCH 24/57] Auto-update README --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index 19bc550..38c2061 100644 --- a/README.md +++ b/README.md @@ -21,7 +21,6 @@ WeKan® is an completely Open Source and Free software collaborative kanban boar **Shipped version:** 6.97~ynh1 - **Demo:** https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h ## Screenshots From 9cd648bcdd0eff48b54bc1bc16b9936e061bb288 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 10 Aug 2023 07:48:42 +0200 Subject: [PATCH 25/57] Update manifest.toml --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index 4672acb..5896d40 100644 --- a/manifest.toml +++ b/manifest.toml @@ -17,7 +17,7 @@ admindoc = "https://github.com/wekan/wekan/wiki" code = "https://github.com/wekan/wekan" [integration] -yunohost = ">= 11.1.21" +yunohost = ">= 11.2" architectures = ["arm64", "amd64"] multi_instance = true ldap = true From 771ef4cd1478ae42c71dd792a8a9dc3928b71607 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Thu, 14 Sep 2023 12:12:21 +0000 Subject: [PATCH 26/57] Auto-update README --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e24822f..38c2061 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in WeKan® is an completely Open Source and Free software collaborative kanban board application. -**Shipped version:** 7.09~ynh1 +**Shipped version:** 6.97~ynh1 **Demo:** https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h From 8384717fae29b8576b39d27447bda18292760c31 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 14 Sep 2023 14:19:44 +0200 Subject: [PATCH 27/57] cleaning --- manifest.toml | 8 ++++---- scripts/_common.sh | 2 +- scripts/install | 22 +++++----------------- scripts/remove | 22 +--------------------- scripts/restore | 18 ++++-------------- scripts/upgrade | 22 +++++----------------- 6 files changed, 20 insertions(+), 74 deletions(-) diff --git a/manifest.toml b/manifest.toml index 5896d40..41292c0 100644 --- a/manifest.toml +++ b/manifest.toml @@ -43,10 +43,10 @@ ram.runtime = "50M" [resources] [resources.sources.main] - arm64.url = "https://github.com/wekan/wekan/releases/download/v6.97/wekan-6.97-arm64.zip" - arm64.sha256 = "3c60fadf67cee852da3e453f32e9548b5ba4f9bd2bdba7e4f60a9f3c4998b08a" - amd64.url = "https://github.com/wekan/wekan/releases/download/v6.97/wekan-6.97-amd64.zip" - amd64.sha256 = "b2637a2a1545a35ac622651aa9d58b58f295ada66cfe9863602aafbfcac90dcc" + arm64.url = "https://github.com/wekan/wekan/releases/download/v7.09/wekan-7.09-arm64.zip" + arm64.sha256 = "0ef14b07dd7fdb635b0350094f3df57aeb6d082e4525fe087e097c4f8cfbf238" + amd64.url = "https://github.com/wekan/wekan/releases/download/v7.09/wekan-7.09-amd64.zip" + amd64.sha256 = "7f9956c878bab40c99d5a7bebdeb1a7fa7d0016098cd47f0946bfde7d997ae7d" autoupdate.strategy = "latest_github_release" autoupdate.asset.amd64 = "*-amd64.zip" autoupdate.asset.arm64 = "*-arm64.zip" diff --git a/scripts/_common.sh b/scripts/_common.sh index c862664..ce74726 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -16,7 +16,7 @@ mongo_version=6.0 #================================================= readonly YNH_DEFAULT_MONGO_VERSION=4.4 -# Declare the actual MongoDB version to use: 4.4 ; 5.0 +# Declare the actual MongoDB version to use: 4.4; 5.0; 6.0 # A packager willing to use another version of MongoDB can override the variable into its _common.sh. YNH_MONGO_VERSION=${YNH_MONGO_VERSION:-$YNH_DEFAULT_MONGO_VERSION} diff --git a/scripts/install b/scripts/install index 6020072..16b2ec0 100644 --- a/scripts/install +++ b/scripts/install @@ -47,6 +47,11 @@ ynh_script_progression --message="Configuring NGINX web server..." # Create a dedicated NGINX config ynh_add_nginx_config +# Create a dedicated systemd config +ynh_add_systemd_config + +yunohost service add $app --description="Wekan daemon" --log="/var/log/$app/$app.log" + #================================================= # SPECIFIC SETUP #================================================= @@ -61,23 +66,6 @@ ynh_add_config --template=".env" --destination="$install_dir/.env" chmod 400 "$install_dir/.env" chown $app:$app "$install_dir/.env" -#================================================= -# SETUP SYSTEMD -#================================================= -ynh_script_progression --message="Configuring a systemd service..." - -# Create a dedicated systemd config -ynh_add_systemd_config - -#================================================= -# GENERIC FINALIZATION -#================================================= -# INTEGRATE SERVICE IN YUNOHOST -#================================================= -ynh_script_progression --message="Integrating service in YunoHost..." - -yunohost service add $app --description="Wekan daemon" - #================================================= # START SYSTEMD SERVICE #================================================= diff --git a/scripts/remove b/scripts/remove index 9b4df5a..8a5c2cd 100755 --- a/scripts/remove +++ b/scripts/remove @@ -30,38 +30,18 @@ then yunohost service remove $app fi -#================================================= -# STOP AND REMOVE SERVICE -#================================================= -ynh_script_progression --message="Stopping and removing the systemd service..." - # Remove the dedicated systemd config ynh_remove_systemd_config -#================================================= -# REMOVE THE MONGODB DATABASE -#================================================= -ynh_script_progression --message="Removing the MongoDB database..." - # Remove a database if it exists, along with the associated user ynh_mongo_remove_db --db_user=$db_user --db_name=$db_name - -#================================================= -# REMOVE NGINX CONFIGURATION -#================================================= -ynh_script_progression --message="Removing NGINX web server configuration..." +ynh_remove_mongo # Remove the dedicated NGINX config ynh_remove_nginx_config -#================================================= -# REMOVE DEPENDENCIES -#================================================= -#REMOVEME? ynh_script_progression --message="Removing dependencies..." - # Remove metapackage and its dependencies ynh_remove_nodejs -ynh_remove_mongo #================================================= # END OF SCRIPT diff --git a/scripts/restore b/scripts/restore index 81efeb8..24ea87e 100644 --- a/scripts/restore +++ b/scripts/restore @@ -32,13 +32,6 @@ ynh_install_nodejs --nodejs_version=$nodejs_version ynh_use_nodejs ynh_install_mongo --mongo_version=$mongo_version -#================================================= -# RESTORE 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" - #================================================= # RESTORE THE MONGODB DATABASE #================================================= @@ -47,18 +40,15 @@ ynh_script_progression --message="Restoring the MongoDB database..." ynh_mongo_restore_db --database="$db_name" < ./dump.bson #================================================= -# RESTORE SYSTEMD +# RESTORE THE NGINX CONFIGURATION #================================================= -ynh_script_progression --message="Restoring the systemd configuration..." +ynh_script_progression --message="Restoring the NGINX web server configuration..." + +ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf" ynh_restore_file --origin_path="/etc/systemd/system/$app.service" systemctl enable $app.service --quiet -#================================================= -# INTEGRATE SERVICE IN YUNOHOST -#================================================= -ynh_script_progression --message="Integrating service in YunoHost..." - yunohost service add $app --description="Wekan daemon" #================================================= diff --git a/scripts/upgrade b/scripts/upgrade index a09b9db..fb95938 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -70,6 +70,11 @@ ynh_script_progression --message="Upgrading NGINX web server configuration..." # Create a dedicated NGINX config ynh_add_nginx_config +# Create a dedicated systemd config +ynh_add_systemd_config + +yunohost service add $app --description="Wekan daemon" --log="/var/log/$app/$app.log" + #================================================= # SPECIFIC UPGRADE #================================================= @@ -84,23 +89,6 @@ ynh_add_config --template=".env" --destination="$install_dir/.env" chmod 400 "$install_dir/.env" chown $app:$app "$install_dir/.env" -#================================================= -# SETUP SYSTEMD -#================================================= -ynh_script_progression --message="Upgrading systemd configuration..." - -# Create a dedicated systemd config -ynh_add_systemd_config - -#================================================= -# GENERIC FINALIZATION -#================================================= -# INTEGRATE SERVICE IN YUNOHOST -#================================================= -ynh_script_progression --message="Integrating service in YunoHost..." - -yunohost service add $app --description="Wekan daemon" - #================================================= # START SYSTEMD SERVICE #================================================= From 7f38c13e5b3228d9951310f729e93630d223139a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 14 Sep 2023 14:22:17 +0200 Subject: [PATCH 28/57] Update restore --- scripts/restore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/restore b/scripts/restore index 24ea87e..1ed10bb 100644 --- a/scripts/restore +++ b/scripts/restore @@ -49,7 +49,7 @@ ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf" ynh_restore_file --origin_path="/etc/systemd/system/$app.service" systemctl enable $app.service --quiet -yunohost service add $app --description="Wekan daemon" +yunohost service add $app --description="Wekan daemon" --log=/var/log/$app/$app.log #================================================= # START SYSTEMD SERVICE From 9a0e3e038f8f42dbec0f3e5892e3c2500c94b7b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 14 Sep 2023 14:26:01 +0200 Subject: [PATCH 29/57] Update restore --- scripts/restore | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/scripts/restore b/scripts/restore index 1ed10bb..b91eee5 100644 --- a/scripts/restore +++ b/scripts/restore @@ -6,7 +6,6 @@ # IMPORT GENERIC HELPERS #================================================= -# 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 @@ -25,7 +24,7 @@ chown -R $app:$app "$install_dir" #================================================= # REINSTALL DEPENDENCIES #================================================= -#REMOVEME? ynh_script_progression --message="Reinstalling dependencies..." +ynh_script_progression --message="Reinstalling dependencies..." # Define and install dependencies ynh_install_nodejs --nodejs_version=$nodejs_version @@ -49,7 +48,7 @@ ynh_restore_file --origin_path="/etc/nginx/conf.d/$domain.d/$app.conf" ynh_restore_file --origin_path="/etc/systemd/system/$app.service" systemctl enable $app.service --quiet -yunohost service add $app --description="Wekan daemon" --log=/var/log/$app/$app.log +yunohost service add $app --description="Wekan daemon" --log="/var/log/$app/$app.log" #================================================= # START SYSTEMD SERVICE From 346adec978a7cb7483cd13bc15e6106ffacd1cd1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 14 Sep 2023 14:28:09 +0200 Subject: [PATCH 30/57] Update manifest.toml --- manifest.toml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/manifest.toml b/manifest.toml index 41292c0..d3a042f 100644 --- a/manifest.toml +++ b/manifest.toml @@ -59,3 +59,6 @@ ram.runtime = "50M" [resources.permissions] main.url = "/" + admin.url = "/admin" + admin.show_tile = false + admin.allowed = "admins" From 3e64ce43667db0c9dfd45adffdd91ba4c32fdb48 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 14 Sep 2023 14:33:57 +0200 Subject: [PATCH 31/57] Update manifest.toml --- manifest.toml | 2 -- 1 file changed, 2 deletions(-) diff --git a/manifest.toml b/manifest.toml index d3a042f..c290f6b 100644 --- a/manifest.toml +++ b/manifest.toml @@ -59,6 +59,4 @@ ram.runtime = "50M" [resources.permissions] main.url = "/" - admin.url = "/admin" - admin.show_tile = false admin.allowed = "admins" From d592dd933a0cc71aa3fc25185cf818b5e3ead210 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 14 Sep 2023 14:41:16 +0200 Subject: [PATCH 32/57] Update systemd.service --- conf/systemd.service | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/conf/systemd.service b/conf/systemd.service index 2b3b3b5..a8e61f0 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -15,5 +15,40 @@ SuccessExitStatus=143 #RestartSec=10 #ExecReload=/bin/kill -USR1 $MAINPID + +# Sandboxing options to harden security +# Depending on specificities of your service/app, you may need to tweak these +# .. but this should be a good baseline +# Details for these options: https://www.freedesktop.org/software/systemd/man/systemd.exec.html +NoNewPrivileges=yes +PrivateTmp=yes +PrivateDevices=yes +RestrictAddressFamilies=AF_UNIX AF_INET AF_INET6 AF_NETLINK +RestrictNamespaces=yes +RestrictRealtime=yes +DevicePolicy=closed +ProtectClock=yes +ProtectHostname=yes +ProtectProc=invisible +ProtectSystem=full +ProtectControlGroups=yes +ProtectKernelModules=yes +ProtectKernelTunables=yes +LockPersonality=yes +SystemCallArchitectures=native +SystemCallFilter=~@clock @debug @module @mount @obsolete @reboot @setuid @swap @cpu-emulation @privileged + +# Denying access to capabilities that should not be relevant for webapps +# Doc: https://man7.org/linux/man-pages/man7/capabilities.7.html +CapabilityBoundingSet=~CAP_RAWIO CAP_MKNOD +CapabilityBoundingSet=~CAP_AUDIT_CONTROL CAP_AUDIT_READ CAP_AUDIT_WRITE +CapabilityBoundingSet=~CAP_SYS_BOOT CAP_SYS_TIME CAP_SYS_MODULE CAP_SYS_PACCT +CapabilityBoundingSet=~CAP_LEASE CAP_LINUX_IMMUTABLE CAP_IPC_LOCK +CapabilityBoundingSet=~CAP_BLOCK_SUSPEND CAP_WAKE_ALARM +CapabilityBoundingSet=~CAP_SYS_TTY_CONFIG +CapabilityBoundingSet=~CAP_MAC_ADMIN CAP_MAC_OVERRIDE +CapabilityBoundingSet=~CAP_NET_ADMIN CAP_NET_BROADCAST CAP_NET_RAW +CapabilityBoundingSet=~CAP_SYS_ADMIN CAP_SYS_PTRACE CAP_SYSLOG + [Install] WantedBy=multi-user.target From 8375ca6f7186bfaf1bb1e44f0264e682770bb6e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 14 Sep 2023 14:42:15 +0200 Subject: [PATCH 33/57] Update systemd.service --- conf/systemd.service | 1 - 1 file changed, 1 deletion(-) diff --git a/conf/systemd.service b/conf/systemd.service index a8e61f0..148183a 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -15,7 +15,6 @@ SuccessExitStatus=143 #RestartSec=10 #ExecReload=/bin/kill -USR1 $MAINPID - # Sandboxing options to harden security # Depending on specificities of your service/app, you may need to tweak these # .. but this should be a good baseline From 9e04f10d2530a8f7a53a4c34227d79cea5c4fc1d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 14 Sep 2023 15:13:07 +0200 Subject: [PATCH 34/57] Update manifest.toml --- manifest.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/manifest.toml b/manifest.toml index c290f6b..ccb507f 100644 --- a/manifest.toml +++ b/manifest.toml @@ -38,8 +38,8 @@ ram.runtime = "50M" type = "group" default = "visitors" - [install.admin] - type = "user" + #[install.admin] + #type = "user" [resources] [resources.sources.main] @@ -59,4 +59,4 @@ ram.runtime = "50M" [resources.permissions] main.url = "/" - admin.allowed = "admins" + #admin.allowed = "admins" From 6a9154b6b70d7b0b536c3bd073c88b1ec3aa001b Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sun, 17 Sep 2023 09:26:33 +0200 Subject: [PATCH 35/57] Update manifest.toml --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index ccb507f..96fc3f3 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Wekan" description.en = "Trello-like kanban" description.fr = "Kanban similaire à Trello" -version = "6.97~ynh1" +version = "7.09~ynh1" maintainers = ["alexAubin", "ljf", "yalh76"] From 5bce3de24297e49cd526e8f67880d71b384ed89e Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Sun, 17 Sep 2023 07:26:37 +0000 Subject: [PATCH 36/57] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 38c2061..e24822f 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in WeKan® is an completely Open Source and Free software collaborative kanban board application. -**Shipped version:** 6.97~ynh1 +**Shipped version:** 7.09~ynh1 **Demo:** https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h diff --git a/README_fr.md b/README_fr.md index 5e1eb5f..de0e079 100644 --- a/README_fr.md +++ b/README_fr.md @@ -19,7 +19,7 @@ Si vous n’avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) po WeKan® est une application de tableau kanban collaborative entièrement libre et open source. -**Version incluse :** 6.97~ynh1 +**Version incluse :** 7.09~ynh1 **Démo :** https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h From 372db8b174eae24f3dd1cb988525c4d825eb90ec Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sun, 17 Sep 2023 09:26:48 +0200 Subject: [PATCH 37/57] Update _common.sh --- scripts/_common.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index ce74726..de68c56 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -5,7 +5,7 @@ #================================================= nodejs_version="14.21.3" -mongo_version=6.0 +mongo_version=5.0 #================================================= # PERSONAL HELPERS From 1dc8c5b8a28f8559d7e7d99e4e70924270dc10eb Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sun, 17 Sep 2023 09:29:45 +0200 Subject: [PATCH 38/57] Update _common.sh --- scripts/_common.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index de68c56..25213d5 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -5,7 +5,6 @@ #================================================= nodejs_version="14.21.3" -mongo_version=5.0 #================================================= # PERSONAL HELPERS From 41c1a6a523e47efe42f0586ebf0b318a2dc203db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 10 Nov 2023 15:41:23 +0100 Subject: [PATCH 39/57] Update restore --- scripts/restore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/restore b/scripts/restore index b91eee5..2de3d09 100644 --- a/scripts/restore +++ b/scripts/restore @@ -29,7 +29,7 @@ ynh_script_progression --message="Reinstalling dependencies..." # Define and install dependencies ynh_install_nodejs --nodejs_version=$nodejs_version ynh_use_nodejs -ynh_install_mongo --mongo_version=$mongo_version +ynh_install_mongo #================================================= # RESTORE THE MONGODB DATABASE From af52a136319df07b1e8377b6913ecf24e53cc0e8 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Fri, 10 Nov 2023 14:41:28 +0000 Subject: [PATCH 40/57] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index e24822f..6131db1 100644 --- a/README.md +++ b/README.md @@ -32,7 +32,7 @@ WeKan® is an completely Open Source and Free software collaborative kanban boar * Official app website: * Official admin documentation: * Upstream app code repository: -* YunoHost documentation for this app: +* YunoHost Store: * Report a bug: ## Developer info diff --git a/README_fr.md b/README_fr.md index de0e079..9eb2d96 100644 --- a/README_fr.md +++ b/README_fr.md @@ -32,7 +32,7 @@ WeKan® est une application de tableau kanban collaborative entièrement libre e * Site officiel de l’app : * Documentation officielle de l’admin : * Dépôt de code officiel de l’app : -* Documentation YunoHost pour cette app : +* YunoHost Store: * Signaler un bug : ## Informations pour les développeurs From 02ac34489a312d72d9986587d33ba981173d028d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 10 Nov 2023 17:40:59 +0100 Subject: [PATCH 41/57] fix --- doc/DESCRIPTION.md | 2 +- doc/DESCRIPTION_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/DESCRIPTION.md b/doc/DESCRIPTION.md index 45d1b5d..87a16d3 100644 --- a/doc/DESCRIPTION.md +++ b/doc/DESCRIPTION.md @@ -1 +1 @@ -WeKan® is an completely Open Source and Free software collaborative kanban board application. +WeKan is an completely Open Source and Free software collaborative kanban board application. diff --git a/doc/DESCRIPTION_fr.md b/doc/DESCRIPTION_fr.md index 90dbc73..e80d155 100644 --- a/doc/DESCRIPTION_fr.md +++ b/doc/DESCRIPTION_fr.md @@ -1 +1 @@ -WeKan® est une application de tableau kanban collaborative entièrement libre et open source. +WeKan est une application de tableau kanban collaborative entièrement libre et open source. From 65f147b23cd24f102edee5a32193242da5a69010 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 14 Nov 2023 11:32:36 +0100 Subject: [PATCH 42/57] Update manifest.toml --- manifest.toml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/manifest.toml b/manifest.toml index 96fc3f3..93b0b95 100644 --- a/manifest.toml +++ b/manifest.toml @@ -20,8 +20,11 @@ code = "https://github.com/wekan/wekan" yunohost = ">= 11.2" architectures = ["arm64", "amd64"] multi_instance = true + ldap = true + sso = false + disk = "50M" ram.build = "50M" ram.runtime = "50M" From b2f347fa71c90a9e3a0ba6c398d07d24b1207dcf Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Tue, 14 Nov 2023 10:32:40 +0000 Subject: [PATCH 43/57] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 6131db1..d5bca1c 100644 --- a/README.md +++ b/README.md @@ -16,7 +16,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in ## Overview -WeKan® is an completely Open Source and Free software collaborative kanban board application. +WeKan is an completely Open Source and Free software collaborative kanban board application. **Shipped version:** 7.09~ynh1 diff --git a/README_fr.md b/README_fr.md index 9eb2d96..0665edc 100644 --- a/README_fr.md +++ b/README_fr.md @@ -16,7 +16,7 @@ Si vous n’avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) po ## Vue d’ensemble -WeKan® est une application de tableau kanban collaborative entièrement libre et open source. +WeKan est une application de tableau kanban collaborative entièrement libre et open source. **Version incluse :** 7.09~ynh1 From 2320a017833f5f9f40fa27d99b4683afe93998cb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 14 Nov 2023 11:38:04 +0100 Subject: [PATCH 44/57] cleaning --- scripts/install | 22 ++++++++++++---------- scripts/remove | 8 -------- scripts/restore | 9 +-------- scripts/upgrade | 4 ++-- 4 files changed, 15 insertions(+), 28 deletions(-) diff --git a/scripts/install b/scripts/install index 16b2ec0..2244860 100644 --- a/scripts/install +++ b/scripts/install @@ -16,17 +16,7 @@ ynh_script_progression --message="Installing dependencies..." ynh_install_nodejs --nodejs_version=$nodejs_version ynh_use_nodejs -ynh_install_mongo -#================================================= -# CREATE A MONGODB DATABASE -#================================================= -ynh_script_progression --message="Creating a MongoDB database..." - -db_name=$(ynh_sanitize_dbid --db_name=$app) -db_user=$db_name -ynh_app_setting_set --app=$app --key=db_name --value=$db_name -ynh_mongo_setup_db --db_user=$db_user --db_name=$db_name #================================================= # DOWNLOAD, CHECK AND UNPACK SOURCE @@ -39,6 +29,18 @@ ynh_setup_source --dest_dir="$install_dir" chmod -R o-rwx "$install_dir" chown -R $app:$app "$install_dir" +#================================================= +# CREATE A MONGODB DATABASE +#================================================= +ynh_script_progression --message="Creating a MongoDB database..." + +db_name=$(ynh_sanitize_dbid --db_name=$app) +db_user=$db_name +ynh_app_setting_set --app=$app --key=db_name --value=$db_name + +ynh_install_mongo +ynh_mongo_setup_db --db_user=$db_user --db_name=$db_name + #================================================= # NGINX CONFIGURATION #================================================= diff --git a/scripts/remove b/scripts/remove index 8a5c2cd..26100a7 100755 --- a/scripts/remove +++ b/scripts/remove @@ -9,14 +9,6 @@ source _common.sh source /usr/share/yunohost/helpers -#================================================= -# LOAD SETTINGS -#================================================= -ynh_script_progression --message="Loading installation settings..." --weight=1 - -db_name=$(ynh_app_setting_get --app=$app --key=db_name) -db_user=$db_name - #================================================= # STANDARD REMOVE #================================================= diff --git a/scripts/restore b/scripts/restore index 2de3d09..e9321d1 100644 --- a/scripts/restore +++ b/scripts/restore @@ -29,13 +29,13 @@ ynh_script_progression --message="Reinstalling dependencies..." # Define and install dependencies ynh_install_nodejs --nodejs_version=$nodejs_version ynh_use_nodejs -ynh_install_mongo #================================================= # RESTORE THE MONGODB DATABASE #================================================= ynh_script_progression --message="Restoring the MongoDB database..." +ynh_install_mongo ynh_mongo_restore_db --database="$db_name" < ./dump.bson #================================================= @@ -61,13 +61,6 @@ if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then sleep 60 fi -#================================================= -# GENERIC FINALIZATION -#================================================= -# RELOAD NGINX -#================================================= -ynh_script_progression --message="Reloading NGINX web server..." - ynh_systemd_action --service_name=nginx --action=reload #================================================= diff --git a/scripts/upgrade b/scripts/upgrade index fb95938..c5143ba 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -9,6 +9,8 @@ source _common.sh source /usr/share/yunohost/helpers +main_domain=$(cat /etc/yunohost/current_host) + #================================================= # CHECK VERSION #================================================= @@ -82,8 +84,6 @@ yunohost service add $app --description="Wekan daemon" --log="/var/log/$app/$app #================================================= ynh_script_progression --message="Updating a configuration file..." -main_domain=$(cat /etc/yunohost/current_host) - ynh_add_config --template=".env" --destination="$install_dir/.env" chmod 400 "$install_dir/.env" From f4d36141fc4be80d936f66d36d5d185e8515b6b3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 14 Nov 2023 11:38:41 +0100 Subject: [PATCH 45/57] cleaning --- scripts/install | 12 ++++++------ scripts/restore | 6 +++--- scripts/upgrade | 6 +++--- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/scripts/install b/scripts/install index 2244860..561050a 100644 --- a/scripts/install +++ b/scripts/install @@ -9,6 +9,9 @@ source _common.sh source /usr/share/yunohost/helpers + +main_domain=$(cat /etc/yunohost/current_host) + #================================================= # INSTALL DEPENDENCIES #================================================= @@ -17,7 +20,6 @@ ynh_script_progression --message="Installing dependencies..." ynh_install_nodejs --nodejs_version=$nodejs_version ynh_use_nodejs - #================================================= # DOWNLOAD, CHECK AND UNPACK SOURCE #================================================= @@ -61,8 +63,6 @@ yunohost service add $app --description="Wekan daemon" --log="/var/log/$app/$app #================================================= ynh_script_progression --message="Adding a config file..." -main_domain=$(cat /etc/yunohost/current_host) - ynh_add_config --template=".env" --destination="$install_dir/.env" chmod 400 "$install_dir/.env" @@ -76,9 +76,9 @@ ynh_script_progression --message="Starting a systemd service..." # Start a systemd service ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Enabling LDAP Background Sync" -if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then - sleep 60 -fi +#if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then +# sleep 60 +#fi #================================================= # END OF SCRIPT diff --git a/scripts/restore b/scripts/restore index e9321d1..f94fca4 100644 --- a/scripts/restore +++ b/scripts/restore @@ -57,9 +57,9 @@ ynh_script_progression --message="Starting a systemd service..." ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Started Wekan, task board" -if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then - sleep 60 -fi +#if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then +# sleep 60 +#fi ynh_systemd_action --service_name=nginx --action=reload diff --git a/scripts/upgrade b/scripts/upgrade index c5143ba..a9742fc 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -96,9 +96,9 @@ ynh_script_progression --message="Starting a systemd service..." ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Started Wekan, task board" -if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then - sleep 60 -fi +#if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then +# sleep 60 +#fi #================================================= # END OF SCRIPT From 168118a08772f4f46226f9beb21d1e22b35b3aa0 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Tue, 14 Nov 2023 10:39:25 +0000 Subject: [PATCH 46/57] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 478530b..d5bca1c 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in WeKan is an completely Open Source and Free software collaborative kanban board application. -**Shipped version:** 7.18~ynh1 +**Shipped version:** 7.09~ynh1 **Demo:** https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h diff --git a/README_fr.md b/README_fr.md index 1b32698..0665edc 100644 --- a/README_fr.md +++ b/README_fr.md @@ -19,7 +19,7 @@ Si vous n’avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) po WeKan est une application de tableau kanban collaborative entièrement libre et open source. -**Version incluse :** 7.18~ynh1 +**Version incluse :** 7.09~ynh1 **Démo :** https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h From 257a5d2a9543b1ce98ea3dc12ead0dc56a2a451a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 14 Nov 2023 11:40:42 +0100 Subject: [PATCH 47/57] Update manifest.toml --- manifest.toml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/manifest.toml b/manifest.toml index 93b0b95..71cc00c 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Wekan" description.en = "Trello-like kanban" description.fr = "Kanban similaire à Trello" -version = "7.09~ynh1" +version = "7.18~ynh1" maintainers = ["alexAubin", "ljf", "yalh76"] @@ -46,10 +46,10 @@ ram.runtime = "50M" [resources] [resources.sources.main] - arm64.url = "https://github.com/wekan/wekan/releases/download/v7.09/wekan-7.09-arm64.zip" - arm64.sha256 = "0ef14b07dd7fdb635b0350094f3df57aeb6d082e4525fe087e097c4f8cfbf238" - amd64.url = "https://github.com/wekan/wekan/releases/download/v7.09/wekan-7.09-amd64.zip" - amd64.sha256 = "7f9956c878bab40c99d5a7bebdeb1a7fa7d0016098cd47f0946bfde7d997ae7d" + arm64.url = "https://github.com/wekan/wekan/releases/download/v7.09/wekan-7.18-arm64.zip" + arm64.sha256 = "6e384614e436147cbe4977ea8dd51f4e45487f455b23efe5e44d74ef6b69ceaf" + amd64.url = "https://github.com/wekan/wekan/releases/download/v7.09/wekan-7.18-amd64.zip" + amd64.sha256 = "da865310d70de763fc0d410344e28a493691e461b5195fe97d16e89f3d0d7246" autoupdate.strategy = "latest_github_release" autoupdate.asset.amd64 = "*-amd64.zip" autoupdate.asset.arm64 = "*-arm64.zip" From 1122cc82969324239a1e29aba600ea63290b26c1 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Tue, 14 Nov 2023 10:40:51 +0000 Subject: [PATCH 48/57] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index d5bca1c..478530b 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in WeKan is an completely Open Source and Free software collaborative kanban board application. -**Shipped version:** 7.09~ynh1 +**Shipped version:** 7.18~ynh1 **Demo:** https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h diff --git a/README_fr.md b/README_fr.md index 0665edc..1b32698 100644 --- a/README_fr.md +++ b/README_fr.md @@ -19,7 +19,7 @@ Si vous n’avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) po WeKan est une application de tableau kanban collaborative entièrement libre et open source. -**Version incluse :** 7.09~ynh1 +**Version incluse :** 7.18~ynh1 **Démo :** https://demo.sandstorm.io/appdemo/m86q05rdvj14yvn78ghaxynqz7u2svw6rnttptxx49g1785cdv1h From 48a746ed0805513095be4a87307d6e6664d13be4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 14 Nov 2023 11:46:46 +0100 Subject: [PATCH 49/57] fix --- conf/.env | 8 ++++---- manifest.toml | 1 + 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/conf/.env b/conf/.env index d5ad827..7198df0 100644 --- a/conf/.env +++ b/conf/.env @@ -26,12 +26,12 @@ ROOT_URL='https://__DOMAIN____PATH__' # https://github.com/wekan/wekan/wiki/Adding-users # https://github.com/wekan/wekan/wiki/Troubleshooting-Mail # https://github.com/wekan/wekan-mongodb/blob/master/docker-compose.yml -MAIL_URL='smtp://__MAIN_DOMAIN__:25/' -MAIL_FROM='Wekan Support ' +MAIL_URL='smtp://__APP__:__MAIL_PWD__@__MAIN_DOMAIN__:25/' +MAIL_FROM='Wekan Support <__APP__@__DOMAIN__>' # Currently MAIL_SERVICE is not in use. #MAIL_SERVICE=Outlook365 -#MAIL_SERVICE_USER=firstname.lastname@hotmail.com -#MAIL_SERVICE_PASSWORD=SecretPassword +#MAIL_SERVICE_USER=__APP__ +#MAIL_SERVICE_PASSWORD=__MAIL_PWD__ #--------------------------------------------- #KADIRA_OPTIONS_ENDPOINT=http://127.0.0.1:11011 #--------------------------------------------- diff --git a/manifest.toml b/manifest.toml index 71cc00c..50bf768 100644 --- a/manifest.toml +++ b/manifest.toml @@ -57,6 +57,7 @@ ram.runtime = "50M" [resources.ports] [resources.system_user] + allow_email = true [resources.install_dir] From 5e0f493393ea5498dfc1f991c0bb8a71eebd9b42 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 14 Nov 2023 12:55:18 +0100 Subject: [PATCH 50/57] fix --- scripts/restore | 2 +- scripts/upgrade | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/restore b/scripts/restore index f94fca4..a7b49a2 100644 --- a/scripts/restore +++ b/scripts/restore @@ -55,7 +55,7 @@ yunohost service add $app --description="Wekan daemon" --log="/var/log/$app/$app #================================================= ynh_script_progression --message="Starting a systemd service..." -ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Started Wekan, task board" +ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Enabling LDAP Background Sync" #if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then # sleep 60 diff --git a/scripts/upgrade b/scripts/upgrade index a9742fc..c694b91 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -94,7 +94,7 @@ chown $app:$app "$install_dir/.env" #================================================= ynh_script_progression --message="Starting a systemd service..." -ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Started Wekan, task board" +ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Enabling LDAP Background Sync" #if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then # sleep 60 From d4883595f6a942d72ffa552e70e7764b95a891a3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 14 Nov 2023 12:56:33 +0100 Subject: [PATCH 51/57] Update tests.toml --- tests.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests.toml b/tests.toml index d35f112..991180e 100644 --- a/tests.toml +++ b/tests.toml @@ -2,4 +2,4 @@ test_format = 1.0 [default] - test_upgrade_from.19d250f0.name = "Upgrade from 6.30" + #test_upgrade_from.19d250f0.name = "Upgrade from 6.30" From eaa8b59ece37886dd0c70c8ac7776027fc1540d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 14 Nov 2023 13:32:41 +0100 Subject: [PATCH 52/57] Update manifest.toml --- manifest.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/manifest.toml b/manifest.toml index 50bf768..9b3b657 100644 --- a/manifest.toml +++ b/manifest.toml @@ -46,9 +46,9 @@ ram.runtime = "50M" [resources] [resources.sources.main] - arm64.url = "https://github.com/wekan/wekan/releases/download/v7.09/wekan-7.18-arm64.zip" + arm64.url = "https://github.com/wekan/wekan/releases/download/v7.18/wekan-7.18-arm64.zip" arm64.sha256 = "6e384614e436147cbe4977ea8dd51f4e45487f455b23efe5e44d74ef6b69ceaf" - amd64.url = "https://github.com/wekan/wekan/releases/download/v7.09/wekan-7.18-amd64.zip" + amd64.url = "https://github.com/wekan/wekan/releases/download/v7.18/wekan-7.18-amd64.zip" amd64.sha256 = "da865310d70de763fc0d410344e28a493691e461b5195fe97d16e89f3d0d7246" autoupdate.strategy = "latest_github_release" autoupdate.asset.amd64 = "*-amd64.zip" From 1513df7bcdbb188a21225a8add55dc9638639136 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 14 Nov 2023 13:32:56 +0100 Subject: [PATCH 53/57] Update nginx.conf --- conf/nginx.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index c1530ef..2c96600 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -1,8 +1,6 @@ #sub_path_only rewrite ^__PATH__$ __PATH__/ permanent; location __PATH__/ { - client_max_body_size 100M; - proxy_pass http://127.0.0.1:__PORT__; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; @@ -11,6 +9,8 @@ location __PATH__/ { # preserve client IP proxy_set_header X-Forwarded-For $remote_addr; + client_max_body_size 100M; + # Include SSOWAT user panel. #include conf.d/yunohost_panel.conf.inc; } From 4735b2a08a0f6417281b3f6bdc027c446adb47be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 14 Nov 2023 14:28:15 +0100 Subject: [PATCH 54/57] Update change_url --- scripts/change_url | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/change_url b/scripts/change_url index 7acfec8..258c657 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -44,7 +44,7 @@ ynh_store_file_checksum --file="$install_dir/.env" ynh_script_progression --message="Starting a systemd service..." # Start a systemd service -ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Started Wekan, task board" +ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Enabling LDAP Background Sync" if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then sleep 60 From 96e48f09be347715944eb5d6058924df0824f959 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 14 Nov 2023 14:47:43 +0100 Subject: [PATCH 55/57] Update change_url --- scripts/change_url | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/change_url b/scripts/change_url index 258c657..7614f0b 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -46,9 +46,9 @@ ynh_script_progression --message="Starting a systemd service..." # Start a systemd service ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Enabling LDAP Background Sync" -if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then - sleep 60 -fi +#if [ ${PACKAGE_CHECK_EXEC:-0} -eq 1 ]; then +# sleep 60 +#fi #================================================= # END OF SCRIPT From 8b2e7043c6a6fe3e62a7a01c7b3889ea13f9645e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 14 Nov 2023 14:48:54 +0100 Subject: [PATCH 56/57] Update tests.toml --- tests.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests.toml b/tests.toml index 991180e..d65a24d 100644 --- a/tests.toml +++ b/tests.toml @@ -2,4 +2,4 @@ test_format = 1.0 [default] - #test_upgrade_from.19d250f0.name = "Upgrade from 6.30" + test_upgrade_from.413b6e0e52fdf162a40313a4f7960f203a0bc64f.name = "Upgrade from 7.09~ynh1" From e2b0e529ed5e148604cf6d1b21a7953d4dc7d59e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 14 Nov 2023 15:30:02 +0100 Subject: [PATCH 57/57] Update manifest.toml --- manifest.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/manifest.toml b/manifest.toml index 9b3b657..40f9d31 100644 --- a/manifest.toml +++ b/manifest.toml @@ -41,8 +41,8 @@ ram.runtime = "50M" type = "group" default = "visitors" - #[install.admin] - #type = "user" + [install.admin] + type = "user" [resources] [resources.sources.main]