mirror of
https://github.com/YunoHost-Apps/limesurvey_ynh.git
synced 2024-09-03 19:36:32 +02:00
[enh] IGNORE when insert user in DB [enh] Add upgrade scripts [enh] Move upload dir in /home
5 lines
373 B
Bash
5 lines
373 B
Bash
#!/bin/bash
|
|
|
|
db_pwd=$(sudo cat /etc/yunohost/mysql)
|
|
user=$1
|
|
mysql -u root -p$db_pwd limesurvey -e "INSERT IGNORE INTO prefix_users (users_name) VALUES ('$user');INSERT IGNORE INTO prefix_permissions (entity,entity_id,uid,permission,create_p,read_p,update_p,delete_p,import_p,export_p) SELECT 'global',0,uid,'surveys',1,1,1,1,0,1 FROM prefix_users WHERE users_name='$user'"
|