1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/mobilizon_ynh.git synced 2024-09-03 19:46:19 +02:00

Merge pull request #80 from YunoHost-Apps/upgrade

Upgrade to 1.0.6-2021-02-17
This commit is contained in:
yalh76 2021-02-25 20:31:53 +01:00 committed by GitHub
commit 129e08cfc3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 61 additions and 93 deletions

View file

@ -13,7 +13,7 @@ Mobilizon aims to solve existing platform's problems to organize events in a dec
Mobilizon is a tool that helps you find, create and organise events. You can also create a page for your group where the members will be able to organise together. Mobilizon is a tool that helps you find, create and organise events. You can also create a page for your group where the members will be able to organise together.
**Shipped version:** 1.0.3 **Shipped version:** 1.0.6-2021-02-23
## Important points to read before installing ## Important points to read before installing
@ -58,8 +58,7 @@ LDAP is supported but HTTP auth is not supported?
--- ---
Developer info ## Developer info
----------------
Please send your pull request to the [testing branch](https://github.com/YunoHost-Apps/mobilizon_ynh/tree/testing). Please send your pull request to the [testing branch](https://github.com/YunoHost-Apps/mobilizon_ynh/tree/testing).

View file

@ -15,20 +15,17 @@
setup_public=1 setup_public=1
upgrade=1 upgrade=1
# 0.1.0-2019-05-15~ynh1 # 0.1.0-2019-05-15~ynh1
upgrade=1 from_commit=185cc16e516076e340cca149e8e9140a8762e22e # upgrade=1 from_commit=185cc16e516076e340cca149e8e9140a8762e22e
# 0.1.0-2019-12-28~ynh1 # 0.1.0-2019-12-28~ynh1
upgrade=1 from_commit=6b77f268d4e7e2cd525e11e11f3ed5a5162d0bd2 # upgrade=1 from_commit=6b77f268d4e7e2cd525e11e11f3ed5a5162d0bd2
# 1.0.0~ynh1 # 1.0.0~ynh1
upgrade=1 from_commit=ac87692da6eaff71f40e3069c7bc6129eddba5e6 # upgrade=1 from_commit=ac87692da6eaff71f40e3069c7bc6129eddba5e6
# 1.0.3~ynh1
# upgrade=1 from_commit=8413ab8bd3aca3e2f6c431153dd9dfab37860956
backup_restore=1 backup_restore=1
multi_instance=1 multi_instance=1
# This test is no longer necessary since the version 2.7 (PR: https://github.com/YunoHost/yunohost/pull/304), you can still do it if your app could be installed with this version.
# incorrect_path=1
port_already_use=0 port_already_use=0
change_url=0 change_url=0
;;; Levels
# If the level 5 (Package linter) is forced to 1. Please add justifications here.
Level 5=auto
;;; Options ;;; Options
Email=yalh@yahoo.com Email=yalh@yahoo.com
Notification=all Notification=all
@ -39,3 +36,5 @@ Notification=all
name=0.1.0-2019-12-28~ynh1 name=0.1.0-2019-12-28~ynh1
; commit=ac87692da6eaff71f40e3069c7bc6129eddba5e6 ; commit=ac87692da6eaff71f40e3069c7bc6129eddba5e6
name=1.0.0~ynh1 name=1.0.0~ynh1
; commit=8413ab8bd3aca3e2f6c431153dd9dfab37860956
name=1.0.3~ynh1

View file

@ -1,6 +1,7 @@
SOURCE_URL=https://framagit.org/framasoft/mobilizon/-/archive/1.0.3/mobilizon-1.0.3.tar.gz SOURCE_URL=https://framagit.org/framasoft/mobilizon/-/archive/82a3995a0de502367150667507e64111bcde6af8/mobilizon-82a3995a0de502367150667507e64111bcde6af8.tar.gz
SOURCE_SUM=5fe588f3567a90c82be8ac1289f836ee2b98b446033c1ca8f9293fd2145441c5 SOURCE_SUM=c83d124d76079949b33328ea9b1bf51d5b4b8d72d3f8517ba9da702af970cc20
SOURCE_SUM_PRG=sha256sum SOURCE_SUM_PRG=sha256sum
SOURCE_FORMAT=tar.gz SOURCE_FORMAT=tar.gz
SOURCE_IN_SUBDIR=true SOURCE_IN_SUBDIR=true
SOURCE_FILENAME=mobilizon-1.0.3.tar.gz SOURCE_FILENAME=mobilizon-1.0.6-2021-02-23.tar.gz
SOURCE_EXTRACT=true

View file

@ -1,11 +1,11 @@
location / { location __PATH__/ {
# Force usage of https # Force usage of https
if ($scheme = http) { if ($scheme = http) {
rewrite ^ https://$server_name$request_uri? permanent; rewrite ^ https://$server_name$request_uri? permanent;
} }
# the nginx default is 1m, not enough for large media uploads # Common parameter to increase upload size limit in conjunction with dedicated php-fpm file
client_max_body_size 16m; client_max_body_size 50M;
proxy_http_version 1.1; proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade; proxy_set_header Upgrade $http_upgrade;

View file

@ -6,11 +6,11 @@ about: When creating a bug report, please use the following template to provide
**How to post a meaningful bug report** **How to post a meaningful bug report**
1. *Read this whole template first.* 1. *Read this whole template first.*
2. *Make sure you are on the right place:* 2. *Determine if you are on the right place:*
- *If you were performing an action on the app from the webadmin or the CLI (install, update, backup, restore, change url...), you are on the right place!* - *If you were performing an action on the app from the webadmin or the CLI (install, update, backup, restore, change_url...), you are on the right place!*
- *Otherwise, the issue may be due to the app itself. Refer to its documentation or repository for help.* - *Otherwise, the issue may be due to Mobilizon itself. Refer to its documentation or repository for help.*
- *In doubt, ask here and we will figure it out together.* - *When in doubt, post here and we will figure it out together.*
3. *Delete these italic comments as you write over them below, and remove this guide.* 3. *Delete the italic comments as you write over them below, and remove this guide.*
--- ---
### Describe the bug ### Describe the bug
@ -36,8 +36,8 @@ about: When creating a bug report, please use the following template to provide
- *If you used the webadmin, please perform the equivalent command from the CLI first.* - *If you used the webadmin, please perform the equivalent command from the CLI first.*
- *If the error occurs in your browser, explain what you did:* - *If the error occurs in your browser, explain what you did:*
1. *Go to '...'* 1. *Go to '...'*
2. *Click on '....'* 2. *Click on '...'*
3. *Scroll down to '....'* 3. *Scroll down to '...'*
4. *See error* 4. *See error*
### Expected behavior ### Expected behavior

View file

@ -6,14 +6,14 @@
"en": "A decentralized and federated platform to organize events", "en": "A decentralized and federated platform to organize events",
"fr": "Une plateforme décentralisée et fédérée pour organiser des événements" "fr": "Une plateforme décentralisée et fédérée pour organiser des événements"
}, },
"version": "1.0.3~ynh1", "version": "1.0.6-2021-02-23~ynh1",
"url": "https://joinmobilizon.org/", "url": "https://joinmobilizon.org/",
"license": "AGPL-3.0-or-later", "license": "AGPL-3.0-or-later",
"maintainer": { "maintainer": {
"name": "yalh76" "name": "yalh76"
}, },
"requirements": { "requirements": {
"yunohost": ">= 4.0" "yunohost": ">= 4.1.3"
}, },
"multi_instance": true, "multi_instance": true,
"services": [ "services": [

View file

@ -13,6 +13,4 @@
## Package_check results ## Package_check results
--- ---
*If you have access to [App Continuous Integration for packagers](https://yunohost.org/#/packaging_apps_ci) you can provide a link to the package_check results like below, replacing '-NUM-' in this link by the PR number and USERNAME by your username on the ci-apps-dev. Or you provide a screenshot or a pastebin of the results* * An automatic package_check will be launch at https://ci-apps-dev.yunohost.org/, when you add a specific comment to your Pull Request: "!testme", "!gogogadgetoci" or "By the power of systemd, I invoke The Great App CI to test this Pull Request!"*
[![Build Status](https://ci-apps-dev.yunohost.org/jenkins/job/mobilizon_ynh%20PR-NUM-%20(USERNAME)/badge/icon)](https://ci-apps-dev.yunohost.org/jenkins/job/mobilizon_ynh%20PR-NUM-%20(USERNAME)/)

View file

@ -53,7 +53,6 @@ ynh_script_progression --message="Storing installation settings..."
ynh_app_setting_set --app=$app --key=domain --value=$domain ynh_app_setting_set --app=$app --key=domain --value=$domain
ynh_app_setting_set --app=$app --key=path --value=$path_url ynh_app_setting_set --app=$app --key=path --value=$path_url
ynh_app_setting_set --app=$app --key=admin --value=$admin ynh_app_setting_set --app=$app --key=admin --value=$admin
ynh_app_setting_set --app=$app --key=is_public --value=$is_public
ynh_app_setting_set --app=$app --key=language --value=$language ynh_app_setting_set --app=$app --key=language --value=$language
ynh_app_setting_set --app=$app --key=admin_email --value=$admin_email ynh_app_setting_set --app=$app --key=admin_email --value=$admin_email
ynh_app_setting_set --app=$app --key=ynh_user_password --value=$ynh_user_password ynh_app_setting_set --app=$app --key=ynh_user_password --value=$ynh_user_password
@ -223,13 +222,14 @@ ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --lin
#================================================= #=================================================
# SETUP SSOWAT # SETUP SSOWAT
#================================================= #=================================================
ynh_script_progression --message="Configuring SSOwat..." ynh_script_progression --message="Configuring permissions..."
# Make app public if necessary # Make app public if necessary
if [ $is_public -eq 1 ] if [ $is_public -eq 1 ]
then then
# unprotected_uris allows SSO credentials to be passed anyway. # Everyone can access the app.
ynh_app_setting_set --app=$app --key=unprotected_uris --value="/" # The "main" permission is automatically created before the install script.
ynh_permission_update --permission="main" --add="visitors"
fi fi
#================================================= #=================================================

View file

@ -117,7 +117,7 @@ ynh_psql_execute_file_as_root --file="./db.sql" --database=$db_name
ynh_script_progression --message="Restoring the systemd configuration..." ynh_script_progression --message="Restoring the systemd configuration..."
ynh_restore_file --origin_path="/etc/systemd/system/$app.service" ynh_restore_file --origin_path="/etc/systemd/system/$app.service"
systemctl enable $app.service systemctl enable $app.service --quiet
#================================================= #=================================================
# INTEGRATE SERVICE IN YUNOHOST # INTEGRATE SERVICE IN YUNOHOST
@ -138,7 +138,7 @@ ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --lin
#================================================= #=================================================
# RELOAD NGINX AND PHP-FPM # RELOAD NGINX AND PHP-FPM
#================================================= #=================================================
ynh_script_progression --message="Reloading nginx web server..." ynh_script_progression --message="Reloading NGINX web server..."
ynh_systemd_action --service_name=nginx --action=reload ynh_systemd_action --service_name=nginx --action=reload

View file

@ -20,7 +20,6 @@ app=$YNH_APP_INSTANCE_NAME
domain=$(ynh_app_setting_get --app=$app --key=domain) domain=$(ynh_app_setting_get --app=$app --key=domain)
path_url=$(ynh_app_setting_get --app=$app --key=path) path_url=$(ynh_app_setting_get --app=$app --key=path)
admin=$(ynh_app_setting_get --app=$app --key=admin) admin=$(ynh_app_setting_get --app=$app --key=admin)
is_public=$(ynh_app_setting_get --app=$app --key=is_public)
final_path=$(ynh_app_setting_get --app=$app --key=final_path) final_path=$(ynh_app_setting_get --app=$app --key=final_path)
language=$(ynh_app_setting_get --app=$app --key=language) language=$(ynh_app_setting_get --app=$app --key=language)
db_name=$(ynh_app_setting_get --app=$app --key=db_name) db_name=$(ynh_app_setting_get --app=$app --key=db_name)
@ -46,25 +45,9 @@ previous_version="${version}"
#================================================= #=================================================
ynh_script_progression --message="Ensuring downward compatibility..." ynh_script_progression --message="Ensuring downward compatibility..."
# Fix is_public as a boolean value if ! ynh_permission_exists --permission="admin"; then
if [ "$is_public" = "Yes" ]; then # Create the required permissions
ynh_app_setting_set --app=$app --key=is_public --value=1 ynh_permission_create --permission="admin" --url="/admin" --allowed=$admin
is_public=1
elif [ "$is_public" = "No" ]; then
ynh_app_setting_set --app=$app --key=is_public --value=0
is_public=0
fi
# If db_name doesn't exist, create it
if [ -z "$db_name" ]; then
db_name=$(ynh_sanitize_dbid --db_name=$app)
ynh_app_setting_set --app=$app --key=db_name --value=$db_name
fi
# If final_path doesn't exist, create it
if [ -z "$final_path" ]; then
final_path=/var/www/$app
ynh_app_setting_set --app=$app --key=final_path --value=$final_path
fi fi
ynh_secure_remove --file="$final_path/$app/priv/data/GeoLite2-City.mmdb" ynh_secure_remove --file="$final_path/$app/priv/data/GeoLite2-City.mmdb"
@ -282,18 +265,6 @@ ynh_script_progression --message="Starting a systemd service..."
ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Access Mobilizon.Web.Endpoint at" ynh_systemd_action --service_name=$app --action="start" --log_path=systemd --line_match="Access Mobilizon.Web.Endpoint at"
#=================================================
# SETUP SSOWAT
#=================================================
ynh_script_progression --message="Upgrading SSOwat configuration..."
# Make app public if necessary
if [ $is_public -eq 1 ]
then
# unprotected_uris allows SSO credentials to be passed anyway
ynh_app_setting_set --app=$app --key=unprotected_uris --value="/"
fi
#================================================= #=================================================
# RELOAD NGINX # RELOAD NGINX
#================================================= #=================================================