From 5b7dab11984af84ccf4a6e444e0d30c4adc64b54 Mon Sep 17 00:00:00 2001 From: D4rkHeart <leonardo.surdez@gmail.com> Date: Tue, 26 Sep 2023 10:41:43 +0200 Subject: [PATCH] [Update] Renamed the config.php template to be used as the real config.php --- Formulaire/configs/config.template.php | 59 -------------------------- 1 file changed, 59 deletions(-) delete mode 100644 Formulaire/configs/config.template.php diff --git a/Formulaire/configs/config.template.php b/Formulaire/configs/config.template.php deleted file mode 100644 index 17199a1..0000000 --- a/Formulaire/configs/config.template.php +++ /dev/null @@ -1,59 +0,0 @@ -<?php - if (count(get_included_files()) == 1) exit("Direct access not permitted."); - - $CONFIG = array( - 'docker' => array( - 'FILESERVERPATH' => '/var/www/html/data/candidatures/', - 'SENDEMAILS' => true, - 'MAIL_FROM' => 'noreply+formulaireApprentis@epfl.ch', - 'MAIL_CONTACT' => 'nicolas.borboen@epfl.ch', - 'MAIL_REPLYTO' => 'nicolas.borboen@epfl.ch', - - 'DB_NAME' => 'canap_db', - 'DB_USER' => 'canap_db', - 'DB_PASS' => 'canap_db', - 'DB_HOST' => 'db', - 'DB_PORT' => '3306', - ), - 'local' => array( - 'FILESERVERPATH' => '/var/www/html/data/candidatures/', - 'SENDEMAILS' => false, - 'MAIL_FROM' => 'noreply+formulaireApprentis@epfl.ch', - 'MAIL_CONTACT' => 'formation.apprentis@epfl.ch', - 'MAIL_REPLYTO' => 'formation.apprentis@epfl.ch', - - 'DB_NAME' => 'canap_db', - 'DB_USER' => 'xxx', - 'DB_PASS' => 'xxx', - 'DB_HOST' => 'localhost', - 'DB_PORT' => '3306', - ), - 'prod' => array( - 'FILESERVERPATH' => '\\\\scxdata.epfl.ch\\apprentis$\\candidatures\\nouvelles\\', - 'SENDEMAILS' => true, - 'MAIL_FROM' => 'noreply+formulaireApprentis@epfl.ch', - 'MAIL_CONTACT' => 'formation.apprentis@epfl.ch', - 'MAIL_REPLYTO' => 'formation.apprentis@epfl.ch', - - 'DB_NAME' => 'canap_db', - 'DB_USER' => 'xxx', - 'DB_PASS' => 'xxx', - 'DB_HOST' => 'mysql-fac.epfl.ch', - 'DB_PORT' => '33003', - ), - ); - - // Change with docker / local / prod - define('ENVIRONMENT', 'docker'); - - if (!isset($_SESSION)) { session_start(); } - - if ($CONFIG[ENVIRONMENT] !== 'prod') { - ini_set("display_errors", 1); - error_reporting(E_ALL); - } else { - ini_set("display_errors", 0); - error_reporting(0); - } - -?> \ No newline at end of file -- GitLab