mirror of
https://github.com/YunoHost-Apps/vikunja_ynh.git
synced 2024-09-03 18:06:26 +02:00
cleaning
This commit is contained in:
parent
6e2b072db6
commit
3f5780c806
8 changed files with 11 additions and 18 deletions
|
@ -21,7 +21,7 @@ service:
|
|||
# The base path on the file system where the binary and assets are.
|
||||
# Vikunja will also look in this path for a config file, so you could provide only this variable to point to a folder
|
||||
# with a config file which will then be used.
|
||||
rootpath: "/opt/vikunja/"
|
||||
rootpath: "__INSTALL_DIR__"
|
||||
# Path on the file system to serve static files from. Set to the path of the frontend files to host frontend alongside the api.
|
||||
staticpath: ""
|
||||
# The max number of items which can be returned per page
|
||||
|
|
|
@ -7,8 +7,8 @@ Requires=postgresql.service redis.service
|
|||
Type=simple
|
||||
User=__APP__
|
||||
Group=__APP__
|
||||
WorkingDirectory=/var/www/__APP__/
|
||||
ExecStart=/var/www/__APP__/vikunja
|
||||
WorkingDirectory=__INSTALL_DIR__/
|
||||
ExecStart=__INSTALL_DIR__/vikunja
|
||||
RestartSec=2s
|
||||
Restart=always
|
||||
|
||||
|
|
|
@ -66,8 +66,6 @@ ram.runtime = "50M"
|
|||
autoupdate.asset.arm64 = "tarball"
|
||||
autoupdate.asset.armhf = "tarball"
|
||||
|
||||
[resources.ports]
|
||||
|
||||
[resources.system_user]
|
||||
allow_email = true
|
||||
|
||||
|
@ -80,6 +78,8 @@ ram.runtime = "50M"
|
|||
api.allowed = "visitors"
|
||||
api.auth_header = false
|
||||
|
||||
[resources.ports]
|
||||
|
||||
[resources.apt]
|
||||
packages = "postgresql"
|
||||
|
||||
|
|
|
@ -18,19 +18,14 @@ ynh_print_info --message="Declaring files to be backed up..."
|
|||
# BACKUP THE APP MAIN DIR
|
||||
#=================================================
|
||||
|
||||
# Frontend
|
||||
ynh_backup --src_path="$install_dir"
|
||||
|
||||
#=================================================
|
||||
# BACKUP THE NGINX CONFIGURATION
|
||||
# SYSTEM CONFIGURATION
|
||||
#=================================================
|
||||
|
||||
ynh_backup --src_path="/etc/nginx/conf.d/$domain.d/$app.conf"
|
||||
|
||||
#=================================================
|
||||
# BACKUP SYSTEMD
|
||||
#=================================================
|
||||
|
||||
ynh_backup --src_path="/etc/systemd/system/$app.service"
|
||||
|
||||
#=================================================
|
||||
|
|
|
@ -40,7 +40,7 @@ ynh_script_progression --message="Adding a configuration file..." --weight=1
|
|||
|
||||
domain="$new_domain"
|
||||
path="$new_path"
|
||||
ynh_add_config --template="../conf/config.yml" --destination="$install_dir/config.yml"
|
||||
ynh_add_config --template="config.yml" --destination="$install_dir/config.yml"
|
||||
|
||||
chmod 600 "$install_dir/config.yml"
|
||||
|
||||
|
|
|
@ -52,7 +52,6 @@ executable="$(find $install_dir -name "vikunja-*" \! -name "*.sha256")"
|
|||
mv "$executable" "$install_dir/vikunja"
|
||||
|
||||
chmod +x "$install_dir/vikunja"
|
||||
|
||||
chmod -R o-rwx "$install_dir"
|
||||
chown -R $app:www-data "$install_dir"
|
||||
|
||||
|
|
|
@ -14,7 +14,6 @@ source /usr/share/yunohost/helpers
|
|||
#=================================================
|
||||
ynh_script_progression --message="Restoring $app main directory..." --weight=4
|
||||
|
||||
# Frontend
|
||||
ynh_restore_file --origin_path="$install_dir"
|
||||
|
||||
chmod -R o-rwx "$install_dir"
|
||||
|
|
|
@ -102,9 +102,9 @@ chmod -R o-rwx "$install_dir"
|
|||
chown -R $app:www-data "$install_dir"
|
||||
|
||||
#=================================================
|
||||
# UPGRADE A CONFIGURATION
|
||||
# UPDATE A CONFIG FILE
|
||||
#=================================================
|
||||
ynh_script_progression --message="Upgrading a configuration file..." --weight=1
|
||||
ynh_script_progression --message="Updating $app's configuration files..." --weight=1
|
||||
|
||||
ynh_add_config --template="config.yml" --destination="$install_dir/config.yml"
|
||||
|
||||
|
@ -112,9 +112,9 @@ chmod 400 "$install_dir/config.yml"
|
|||
chown $app:$app "$install_dir/config.yml"
|
||||
|
||||
#=================================================
|
||||
# NGINX CONFIGURATION
|
||||
# REAPPLY SYSTEM CONFIGURATIONS
|
||||
#=================================================
|
||||
ynh_script_progression --message="Upgrading NGINX web server configuration..." --weight=2
|
||||
ynh_script_progression --message="Upgrading system configurations related to $app..." --weight=1
|
||||
|
||||
ynh_add_nginx_config
|
||||
|
||||
|
|
Loading…
Reference in a new issue