mirror of
https://github.com/YunoHost-Apps/dolibarr_ynh.git
synced 2024-09-03 18:35:53 +02:00
cc4c506757
Major rework of the app: - Update to latest sources - Auto-install - Install, upgrade, remove, backup, restore scripts - Readme - Sets up LDAP (still a bug to solve with the passwords preventing LDAP auth) - Sync YNH users with Dolibarr users and/or members - Check_process (broken because of CURL?) - Hooks (broken)
17 lines
470 B
Bash
17 lines
470 B
Bash
#!/bin/bash
|
|
app=YNH_APP
|
|
src_path=/var/www/$app
|
|
user=YNH_USER
|
|
member=YNH_MEMBER
|
|
|
|
# If YNH users should be users, sync users
|
|
if [ $user = 1 ];
|
|
then
|
|
sudo sudo -u www-data php $src_path/scripts/user/sync_users_ldap2dolibarr.php commitiferror --server=localhost -y
|
|
fi
|
|
|
|
# If YNH users should be members, sync members
|
|
if [ $member = 1 ];
|
|
then
|
|
sudo sudo -u www-data php $src_path/scripts/members/sync_members_ldap2dolibarr.php commitiferror 1 --server=localhost -y
|
|
fi
|