diff --git a/.env b/.env index 6978c73..2d3022a 100644 --- a/.env +++ b/.env @@ -1,5 +1,13 @@ CONTAINER_PORT=9088 UID=1000 +CI_ENV=development +# $arr["host"] = "10.10.10.23"; +# $arr["name"] = "wrenchboard"; +# $arr["user"] = "wrenchboard"; +# $arr["pass"] = "wrenchboard"; +# $arr["port"] = 5432; + + #-------------------------------------------------------------------- # Example Environment Configuration file # diff --git a/app/Config/Database.php b/app/Config/Database.php index 7a1fd21..12ccebe 100644 --- a/app/Config/Database.php +++ b/app/Config/Database.php @@ -4,6 +4,8 @@ namespace Config; use CodeIgniter\Database\Config; +include('config.'.$_SERVER['CI_ENV'].'.php'); +//include 'config.development.php'; /** * Database Configuration */ @@ -24,7 +26,35 @@ class Database extends Config * * @var array */ + public array $default = [ + 'DSN' => '', + 'hostname' => '10.20.30.60', + 'username' => 'wrenchboard', + 'password' => 'wrenchboard', + 'database' => 'wrenchboard', + 'DBDriver' => 'postgre', + 'DBPrefix' => '', + 'pConnect' => false, + 'DBDebug' => true, + 'charset' => 'utf8mb4', + 'DBCollat' => 'utf8mb4_general_ci', + 'swapPre' => '', + 'encrypt' => false, + 'compress' => false, + 'strictOn' => false, + 'failover' => [], + 'port' => 3306, + 'numberNative' => false, + 'dateFormat' => [ + 'date' => 'Y-m-d', + 'datetime' => 'Y-m-d H:i:s', + 'time' => 'H:i:s', + ], + ]; + + + public array $default00 = [ 'DSN' => '', 'hostname' => 'localhost', 'username' => '', diff --git a/app/Config/config.development.php b/app/Config/config.development.php new file mode 100644 index 0000000..e884113 --- /dev/null +++ b/app/Config/config.development.php @@ -0,0 +1,16 @@ +