mirror of
https://github.com/YunoHost-Apps/opentracker_ynh.git
synced 2024-09-03 19:46:34 +02:00
set permissions
This commit is contained in:
parent
ec1906aab1
commit
9ec6fc0456
7 changed files with 13 additions and 9 deletions
|
@ -21,6 +21,10 @@ OpenTracker is a open and free bittorrent tracker project. It aims for minimal r
|
|||
|
||||
`udp://mydomain.com:6969`
|
||||
|
||||
by default the tracker will run on 6969 port on both UDP and TCP.
|
||||
|
||||
visit `http://serverIP:6969/stats` to view the tracker stats.
|
||||
|
||||
## Documentation
|
||||
|
||||
* Official documentation: http://erdgeist.org/arts/software/opentracker/index/#overview
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
;; Test complet
|
||||
; Manifest
|
||||
domain="domain.tld" (DOMAIN)
|
||||
path="/" (PATH)
|
||||
path="/path" (PATH)
|
||||
is_public=1 (PUBLIC|public=1|private=0)
|
||||
port="9980" (PORT)
|
||||
; Checks
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
[Unit]
|
||||
Description=opentracker
|
||||
Description=OpenTracker
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
User=admin
|
||||
Group=users
|
||||
User=__APP__
|
||||
Group=__APP__
|
||||
Type=simple
|
||||
UMask=000
|
||||
WorkingDirectory=__FINALPATH__
|
||||
|
|
|
@ -35,7 +35,7 @@ app=$YNH_APP_INSTANCE_NAME
|
|||
#=================================================
|
||||
ynh_script_progression --message="Validating installation parameters..." --weight=1
|
||||
|
||||
final_path=/home/admin/$app
|
||||
final_path=/opt/$app
|
||||
test ! -e "$final_path" || ynh_die "This path already contains a folder"
|
||||
|
||||
# Register (book) web path
|
||||
|
@ -113,7 +113,7 @@ ynh_add_systemd_config
|
|||
#=================================================
|
||||
|
||||
# Set permissions to app files
|
||||
chown -R admin:1007 $final_path
|
||||
chown -R $app: $final_path
|
||||
chmod +x $final_path/opentracker
|
||||
|
||||
#=================================================
|
||||
|
|
|
@ -26,7 +26,7 @@ final_path=$(ynh_app_setting_get --app=$app --key=final_path)
|
|||
# REMOVE SERVICE INTEGRATION IN YUNOHOST
|
||||
#=================================================
|
||||
|
||||
# Remove the service from the list of services known by Yunohost (added from `yunohost service add`)
|
||||
# Remove the service from the list of services known by YunoHost (added from `yunohost service add`)
|
||||
if ynh_exec_warn_less yunohost service status $app >/dev/null
|
||||
then
|
||||
ynh_script_progression --message="Removing $app service integration..." --weight=1
|
||||
|
|
|
@ -68,7 +68,7 @@ ynh_system_user_create --username=$app
|
|||
#=================================================
|
||||
|
||||
# Restore permissions on app files
|
||||
chown -R root: $final_path
|
||||
chown -R $app: $final_path
|
||||
|
||||
#=================================================
|
||||
# SPECIFIC RESTORATION
|
||||
|
|
|
@ -115,7 +115,7 @@ ynh_add_systemd_config
|
|||
#=================================================
|
||||
|
||||
# Set permissions on app files
|
||||
chown -R root: $final_path
|
||||
chown -R $app: $final_path
|
||||
|
||||
#=================================================
|
||||
# INTEGRATE SERVICE IN YUNOHOST
|
||||
|
|
Loading…
Reference in a new issue