mirror of
https://github.com/YunoHost-Apps/tube_ynh.git
synced 2024-09-04 01:46:11 +02:00
parent
531c98d396
commit
cabb7027fc
6 changed files with 11 additions and 14 deletions
|
@ -8,7 +8,7 @@
|
|||
"server": {
|
||||
"host": "127.0.0.1",
|
||||
"port": __PORT__,
|
||||
"store_path": "__DATADIR__/tube.db",
|
||||
"store_path": "tube.db",
|
||||
"upload_path": "__DATADIR__/uploads",
|
||||
"max_upload_size": __MAX_UPLOAD_SIZE__
|
||||
},
|
||||
|
|
|
@ -7,7 +7,7 @@ Type=simple
|
|||
User=__APP__
|
||||
Group=__APP__
|
||||
WorkingDirectory=__FINALPATH__/
|
||||
ExecStart=__FINALPATH__/tube -c __DATADIR__/config.json
|
||||
ExecStart=__FINALPATH__/tube -c __FINALPATH__/config.json
|
||||
|
||||
# Sandboxing options to harden security
|
||||
# Depending on specificities of your service/app, you may need to tweak these
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
|
||||
Your video files are stored by default in `/home/yunohost.app/tube/videos`.
|
||||
|
||||
You can configure options in this file `/home/yunohost.app/tube/config.json` using the [documentation](https://git.mills.io/prologic/tube#configuration). Remember to restart Tube service if you change your configuration file.
|
||||
You can configure options in this file `/var/www/tube/config.json` using the [documentation](https://git.mills.io/prologic/tube#configuration). Remember to restart Tube service if you change your configuration file.
|
||||
|
||||
RSS feed address is available at `https://your_domain.tld/feed.xml`
|
||||
|
||||
The data directory with uploaded videos and the configuration file is untouched when upgrading the app. If you want to delete the data directory with the application, use the `--purge` option: `sudo yunohost app remove tube --purge`
|
||||
|
|
|
@ -129,10 +129,10 @@ chown -R $app:www-data "$datadir"
|
|||
#=================================================
|
||||
ynh_script_progression --message="Adding a configuration file..." --weight=1
|
||||
|
||||
ynh_add_config --template="../conf/config.json" --destination="$datadir/config.json"
|
||||
ynh_add_config --template="../conf/config.json" --destination="$final_path/config.json"
|
||||
|
||||
chmod 400 "$datadir/config.json"
|
||||
chown $app:$app "$datadir/config.json"
|
||||
chmod 400 "$final_path/config.json"
|
||||
chown $app:$app "$final_path/config.json"
|
||||
|
||||
#=================================================
|
||||
# SETUP SYSTEMD
|
||||
|
|
|
@ -20,7 +20,6 @@ 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)
|
||||
port=$(ynh_app_setting_get --app=$app --key=port)
|
||||
datadir=$(ynh_app_setting_get --app=$app --key=datadir)
|
||||
|
||||
max_upload_size=$(ynh_app_setting_get --app=$app --key=max_upload_size)
|
||||
feed_title=$(ynh_app_setting_get --app=$app --key=feed_title)
|
||||
|
@ -124,7 +123,7 @@ then
|
|||
ynh_script_progression --message="Upgrading source files..." --weight=1
|
||||
|
||||
# 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="$final_path" --source_id=$YNH_ARCH --keep="config.json"
|
||||
fi
|
||||
|
||||
chmod 750 "$final_path"
|
||||
|
|
Loading…
Add table
Reference in a new issue