minor fix in the vagrant bootstrap script.

pull/86/head
Cédric Bonhomme 2017-12-15 15:19:00 +01:00
parent 1c67f1a57f
commit 030bb9bbc5
No known key found for this signature in database
GPG Key ID: A1CB94DE57B7A70D
1 changed files with 7 additions and 5 deletions

View File

@ -149,12 +149,12 @@ service apache2 restart > /dev/null 2>&1
echo -e "\n--- Configuration of MONARC data base connection ---\n"
cat > config/autoload/local.php <<EOF
<?php
$appdir = getenv('APP_DIR') ? getenv('APP_DIR') : '$PATH_TO_MONARC';
$string = file_get_contents($appdir.'/package.json');
if($string === FALSE) {
$string = file_get_contents('./package.json');
\$appdir = getenv('APP_DIR') ? getenv('APP_DIR') : '$PATH_TO_MONARC';
\$string = file_get_contents(\$appdir.'/package.json');
if(\$string === FALSE) {
\$string = file_get_contents('./package.json');
}
$package_json = json_decode($string, true);
\$package_json = json_decode(\$string, true);
return array(
'doctrine' => array(
@ -196,6 +196,8 @@ return array(
*/
'activeLanguages' => array('fr','en','de','ne',),
'appVersion' => \$package_json['version'],
'email' => [
'name' => 'MONARC',
'from' => 'info@monarc.lu',