mirror of
https://github.com/YunoHost-Apps/linuxdash_ynh.git
synced 2024-09-03 19:36:07 +02:00
Ask for YunoHost user which have access to the application.
This commit is contained in:
parent
ae7f617c2a
commit
7f603ddeb3
2 changed files with 13 additions and 0 deletions
|
@ -37,6 +37,15 @@
|
|||
},
|
||||
"example": "/dash",
|
||||
"default": "/dash"
|
||||
},
|
||||
{
|
||||
"name": "user",
|
||||
"type": "user",
|
||||
"ask": {
|
||||
"en": "Choose the YunoHost user who got access to Linux-Dash",
|
||||
"fr": "Choisissez l’utilisateur YunoHost qui a accès à Linux-Dash"
|
||||
},
|
||||
"example": "john"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
@ -5,6 +5,7 @@ app=linuxdash
|
|||
# Retrieve arguments
|
||||
domain=$1
|
||||
path=$2
|
||||
user=$3
|
||||
|
||||
# Check domain/path availability
|
||||
sudo yunohost app checkurl $domain$path -a $app
|
||||
|
@ -33,5 +34,8 @@ sudo cp ../conf/nginx.conf $nginxconf
|
|||
sudo chown root: $nginxconf
|
||||
sudo chmod 600 $nginxconf
|
||||
|
||||
sudo yunohost app removeaccess $app
|
||||
sudo yunohost app addaccess $app -u $user
|
||||
|
||||
# Reload web server
|
||||
sudo service nginx reload
|
||||
|
|
Loading…
Reference in a new issue