mirror of
https://github.com/YunoHost-Apps/dolibarr_ynh.git
synced 2024-09-03 18:35:53 +02:00
Replaced sed by ynh_add_nginx_config
This commit is contained in:
parent
4d73ccbc8d
commit
128c0bf96b
3 changed files with 13 additions and 12 deletions
|
@ -5,10 +5,9 @@ user=YNH_USER
|
|||
member=YNH_MEMBER
|
||||
|
||||
# Sync users
|
||||
sudo sudo -u www-data php $src_path/scripts/user/sync_users_ldap2dolibarr.php commitiferror --server=localhost -y
|
||||
sudo -u www-data php $src_path/scripts/user/sync_users_ldap2dolibarr.php commitiferror --server=localhost -y
|
||||
|
||||
# If YNH users should also be members, sync members
|
||||
if [ $member = 1 ];
|
||||
then
|
||||
if [ $member = 1 ] ; then
|
||||
sudo sudo -u www-data php $src_path/scripts/members/sync_members_ldap2dolibarr.php commitiferror 1 --server=localhost -y
|
||||
fi
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
"url": "https://www.dolibarr.org/",
|
||||
"license": "free",
|
||||
"maintainer": {
|
||||
"name": "scith",
|
||||
"url": "https://github.com/scith"
|
||||
"name": "poilou",
|
||||
"url": "https://github.com/labiloute"
|
||||
},
|
||||
"requirements": {
|
||||
"yunohost": ">> 2.7.0"
|
||||
|
|
|
@ -99,11 +99,13 @@ ynh_webpath_register $app $domain $path_url
|
|||
ynh_mysql_create_db "$dbname" "$dbuser" "$dbpass"
|
||||
|
||||
# Modify Nginx configuration file and copy it to Nginx conf directory
|
||||
nginx_conf=../conf/nginx.conf
|
||||
sed -i "s@__PATH__@${path_url}@g" $nginx_conf
|
||||
sed -i "s@__FINALPATH__@$src_path/htdocs/@g" $nginx_conf
|
||||
sed -i "s@__NAME__@$app@g" $nginx_conf
|
||||
sudo cp $nginx_conf /etc/nginx/conf.d/$domain.d/$app.conf
|
||||
# nginx_conf=../conf/nginx.conf
|
||||
# sed -i "s@__PATH__@${path_url}@g" $nginx_conf
|
||||
# sed -i "s@__FINALPATH__@$src_path/htdocs/@g" $nginx_conf
|
||||
# sed -i "s@__NAME__@$app@g" $nginx_conf
|
||||
# sudo cp $nginx_conf /etc/nginx/conf.d/$domain.d/$app.conf
|
||||
|
||||
ynh_add_nginx_config
|
||||
|
||||
# PHP
|
||||
sed -i "s@YNH_WWW_APP@$app@g" ../conf/php-fpm.conf
|
||||
|
|
Loading…
Reference in a new issue