1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/movim_ynh.git synced 2024-09-03 19:46:19 +02:00
* Simplify config
* Set requirementsto 4.2.4
This commit is contained in:
Éric Gaspar 2021-05-15 08:28:00 +02:00 committed by GitHub
parent feb93583a8
commit 537eda073d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 54 additions and 54 deletions

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**
1. *Read this whole template first.*
2. *Make sure you are on the right place:*
- *If you were performing an action on Movim from the webadmin or the CLI (install, update, backup, restore, change_url...), 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!*
- *Otherwise, the issue may be due to the app itself. Refer to its documentation or repository for help.*
- *In doubt, ask here and we will figure it out together.*
3. *Delete these italic comments as you write over them below, and remove this guide.*
- *When in doubt, post here and we will figure it out together.*
3. *Delete the italic comments as you write over them below, and remove this guide.*
---
### Describe the bug
@ -31,7 +31,7 @@ about: When creating a bug report, please use the following template to provide
- *If you performed a command from the CLI, the command itself is enough. For example:*
```sh
sudo yunohost app install movim
sudo yunohost app install the_app
```
- *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:*

16
.github/PULL_REQUEST_TEMPLATE.md vendored Normal file
View file

@ -0,0 +1,16 @@
## Problem
- *Description of why you made this PR*
## Solution
- *And how do you fix that problem*
## PR Status
- [ ] Code finished and ready to be reviewed/tested
- [ ] The fix/enhancement were manually tested (if applicable)
## Automatic tests
Automatic tests can be triggered on https://ci-apps-dev.yunohost.org/ *after creating the PR*, by commenting "!testme", "!gogogadgetoci" or "By the power of systemd, I invoke The Great App CI to test this Pull Request!". (N.B. : for this to work you need to be a member of the Yunohost-Apps organization)

View file

@ -3,10 +3,10 @@
;; Test complet
; Manifest
domain="domain.tld" (DOMAIN)
path="/path" (PATH)
admin="john" (USER)
is_public=1 (PUBLIC|public=1|private=0)
domain="domain.tld"
path="/path"
admin="john"
is_public=1
password="phrasedepasse"
language="fr"
port=9537 (PORT)

12
doc/DISCLAIMER.md Normal file
View file

@ -0,0 +1,12 @@
* Any known limitations, constrains or stuff not working, such as (but not limited to):
* requiring a full dedicated domain ?
* architectures not supported ?
* not-working single-sign on or LDAP integration ?
* the app requires an important amount of RAM / disk / .. to install or to work properly
* etc...
* Other infos that people should be aware of, such as:
* any specific step to perform after installing (such as manually finishing the install, specific admin credentials, ...)
* how to configure / administrate the application if it ain't obvious
* upgrade process / specificities / things to be aware of ?
* security considerations ?

View file

@ -14,7 +14,7 @@
"email": ""
},
"requirements": {
"yunohost": ">= 4.1.7"
"yunohost": ">= 4.2.4"
},
"multi_instance": false,
"services": [

View file

@ -1,16 +0,0 @@
## Problem
- *Description of why you made this PR*
## Solution
- *And how do you fix that problem*
## PR Status
- [ ] Code finished.
- [ ] Tested with Package_check.
- [ ] Fix or enhancement tested.
- [ ] Upgrade from last version tested.
- [ ] Can be reviewed and tested.
## Package_check 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!"*

View file

@ -9,6 +9,8 @@ pkg_dependencies="postgresql postgresql-contrib apt-transport-https"
YNH_PHP_VERSION="7.3"
YNH_COMPOSER_VERSION="2.0.13"
extra_php_dependencies="php${YNH_PHP_VERSION}-curl php${YNH_PHP_VERSION}-mbstring php${YNH_PHP_VERSION}-imagick php${YNH_PHP_VERSION}-gd php${YNH_PHP_VERSION}-pgsql php${YNH_PHP_VERSION}-xml"
#=================================================

View file

@ -132,32 +132,22 @@ ynh_store_file_checksum --file="$final_path/config/db.inc.php"
#=================================================
ynh_script_progression --message="Configuring Composer..." --weight=1
pushd $final_path
export COMPOSER_HOME=$final_path
ynh_exec_warn_less curl -sS https://getcomposer.org/installer | php${phpversion} -- --version="1.10.16" --install-dir="$final_path" \
&& php${phpversion} composer.phar install --no-interaction --quiet
popd
ynh_install_composer
#=================================================
# SETUP SYSTEMD
#=================================================
ynh_script_progression --message="Configuring a systemd service..." --weight=12
ynh_replace_string --match_string="__DOMAIN__" --replace_string="$domain" --target_file=../conf/systemd.service
ynh_replace_string --match_string="__PATH__" --replace_string="$path_url" --target_file=../conf/systemd.service
ynh_replace_string --match_string="__PORT__" --replace_string="$port" --target_file=../conf/systemd.service
ynh_replace_string --match_string="__PHPVERSION__" --replace_string="$phpversion" --target_file=../conf/systemd.service
ynh_add_systemd_config
#=================================================
# Set-up database and configuration
# SET-UP DATABASE AND CONFIGURATION
#=================================================
ynh_script_progression --message="Configuring database..." --weight=1
cache_dir="/home/$app"
ynh_script_progression --message="Configuring Movim..." --weight=1
# Create cachedir folder
cache_dir="/home/yunohost.app/$app"
mkdir -p $cache_dir
chown -R $app $cache_dir
@ -172,9 +162,9 @@ popd
# SET PERMISSIONS
#=================================================
chown -R $app:www-data $final_path
chown -R $app $final_path/src/Movim/
chmod u+rwx $final_path
chmod 750 "$final_path"
chmod -R o-rwx "$final_path"
chown -R $app:www-data "$final_path"
#=================================================
# INTEGRATE SERVICE IN YUNOHOST

View file

@ -73,8 +73,9 @@ ynh_system_user_create --username=$app
#=================================================
# Restore permissions on app files
chown -R $app:www-data $final_path
chown -R $app $final_path/src/Movim/
chmod 750 "$final_path"
chmod -R o-rwx "$final_path"
chown -R $app:www-data "$final_path"
#=================================================
# RESTORE THE PHP-FPM CONFIGURATION

View file

@ -128,9 +128,9 @@ ynh_add_fpm_config --package="$extra_php_dependencies"
# SET PERMISSIONS
#=================================================
chown -R $app:www-data $final_path
chown -R $app $final_path/src/Movim/Bootstrap.php
chmod u+rwx $final_path
chmod 750 "$final_path"
chmod -R o-rwx "$final_path"
chown -R $app:www-data "$final_path"
#=================================================
# INTEGRATE SERVICE IN YUNOHOST
@ -145,7 +145,7 @@ yunohost service add $app --description="Responsive web-based XMPP client" --log
ynh_script_progression --message="Installing Composer..." --weight=1
pushd "$final_path"
ynh_exec_warn_less curl -sS https://getcomposer.org/installer | php$phpversion -- --version="1.10.16" --install-dir="$final_path" \
ynh_exec_warn_less ynh_install_composer \
&& php$phpversion composer.phar config --global discard-changes true --quiet \
&& php$phpversion composer.phar update --no-interaction --quiet \
&& php$phpversion composer.phar movim:migrate --quiet
@ -156,11 +156,6 @@ popd
#=================================================
ynh_script_progression --message="Upgrading systemd configuration..." --weight=5
ynh_replace_string --match_string="__DOMAIN__" --replace_string="$domain" --target_file=../conf/systemd.service
ynh_replace_string --match_string="__PATH__" --replace_string="$path_url" --target_file=../conf/systemd.service
ynh_replace_string --match_string="__PORT__" --replace_string="$port" --target_file=../conf/systemd.service
ynh_replace_string --match_string="__PHPVERSION__" --replace_string="$phpversion" --target_file=../conf/systemd.service
ynh_add_systemd_config
#=================================================