1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/domoticz_ynh.git synced 2024-09-03 18:26:17 +02:00

correct usermod

This commit is contained in:
Krakinou 2021-02-05 12:56:39 +01:00
parent 3f2e43c4c3
commit a1429a859d
4 changed files with 11 additions and 4 deletions

View file

@ -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 REPLACEBYYOURAPP
sudo yunohost app install domoticz_ynh
```
- *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:*

View file

@ -120,7 +120,10 @@ ynh_script_progression --message="Configuring system user..." --weight=1
# Create a system user
ynh_system_user_create --username=$app
#allow user to access USB / serial port to communicate with tools (RFXtrx, Z-wave dongle, etc.) & i2c bus
usermod -a -G dialout i2c gpio $app
usermod -a -G dialout $app
usermod -a -G i2c $app
usermod -a -G gpio $app
#allow app user to restart service on startup
cp ../conf/sudoer ../conf/$app.conf

View file

@ -92,7 +92,9 @@ ynh_restore_file --origin_path="/etc/sudoers.d/$app"
#Both folder and database file must be own by app user for domoticz to work and allow internal upgrade
chown -R $app: $final_path
#allow user to access USB / serial port to communicate with tools (RFXtrx, Z-wave dongle, etc.) & i2c bus
usermod -a -G dialout i2c gpio $app
usermod -a -G dialout $app
usermod -a -G i2c $app
usermod -a -G gpio $app
#=================================================

View file

@ -175,7 +175,9 @@ ynh_script_progression --message="Making sure dedicated system user exists..."
# Create a dedicated user (if not existing)
ynh_system_user_create --username=$app
#allow user to access USB / serial port to communicate with tools (RFXtrx, Z-wave dongle, etc.) & i2c bus
usermod -a -G dialout i2c gpio $app
usermod -a -G dialout $app
usermod -a -G i2c $app
usermod -a -G gpio $app
#allow app user to restart service on startup
cp ../conf/sudoer ../conf/$app.conf