mirror of
https://github.com/YunoHost-Apps/spip_ynh.git
synced 2024-09-03 20:25:59 +02:00
Installation de la conf nginx incorrect + debut configuration SPIP BDD
This commit is contained in:
parent
13934c8d12
commit
f7482b5400
2 changed files with 18 additions and 4 deletions
5
conf/config.php
Normal file
5
conf/config.php
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
<?php
|
||||||
|
if (!defined("_ECRIRE_INC_VERSION")) return;
|
||||||
|
$GLOBALS['spip_connect_version'] = 0.8;
|
||||||
|
spip_connect_db('localhost','','__DB_USER__','__DB_PWD__','spip','mysql', 'spip','','');
|
||||||
|
?>
|
|
@ -54,13 +54,22 @@ sudo chown -R www-data: $final_path
|
||||||
|
|
||||||
echo -e "127.0.0.1 $domain #SPIP" | sudo tee -a /etc/hosts
|
echo -e "127.0.0.1 $domain #SPIP" | sudo tee -a /etc/hosts
|
||||||
|
|
||||||
# Modify Nginx configuration file and copy it to Nginx conf directory
|
# Et copie le fichier de config nginx
|
||||||
sed -i "s@PATHTOCHANGE@$path@g" ../conf/nginx.conf
|
sudo cp ../conf/nginx.conf /etc/nginx/conf.d/$domain.d/$app.conf
|
||||||
sed -i "s@ALIASTOCHANGE@$final_path@g" ../conf/nginx.conf
|
|
||||||
sudo cp ../conf/nginx.conf /etc/nginx/conf.d/$domain.d/spip.conf
|
# Modifie les variables dans le fichier de configuration nginx
|
||||||
|
sudo sed -i "s@__PATHTOCHANGE__@$path@g" /etc/nginx/conf.d/$domain.d/$app.conf
|
||||||
|
sudo sed -i "s@__FINALPATH__@$final_path@g" /etc/nginx/conf.d/$domain.d/$app.conf
|
||||||
|
sudo sed -i "s@__NAMETOCHANGE__@$app@g" /etc/nginx/conf.d/$domain.d/$app.conf
|
||||||
|
|
||||||
POOL_FPM
|
POOL_FPM
|
||||||
|
|
||||||
|
sudo cp ../conf/config.php $final_path/config/config.php
|
||||||
|
|
||||||
|
# Changer les variables du ficher de configuration de SPIP
|
||||||
|
sudo sed -i "s/__DB_USER__/$db_user/g" $final_path/config/config.php
|
||||||
|
sudo sed -i "s/__DB_PWD__/$db_pwd/g" $final_path/config/config.php
|
||||||
|
|
||||||
# Donne un accès public pour curl
|
# Donne un accès public pour curl
|
||||||
ynh_app_setting_set $app unprotected_uris "/"
|
ynh_app_setting_set $app unprotected_uris "/"
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue