From 51774c0cc999d9f8994ceedabacb2b9a147e9158 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timoth=C3=A9e=20Jaussoin?= Date: Wed, 26 Oct 2022 11:12:21 +0200 Subject: [PATCH] Fix #51 Use DB_CONNECTION and not DB_DRIVER by default to configure the database access --- flexiapi/.env.example | 4 ++-- flexiapi/config/database.php | 4 ++-- flexisip-account-manager.spec | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/flexiapi/.env.example b/flexiapi/.env.example index f4c07b7..1c8afa5 100644 --- a/flexiapi/.env.example +++ b/flexiapi/.env.example @@ -46,9 +46,9 @@ PRIVACY_POLICY_URL= # A URL pointing to the Privacy Policy LOG_CHANNEL=stack -# External FlexiSIP database +# FlexiSIP database # Ensure that you have the proper SELinux configuration to allow database connections, see the README -DB_DRIVER=mysql +DB_CONNECTION=mysql DB_HOST=127.0.0.1 DB_PORT=3306 DB_DATABASE=flexisip diff --git a/flexiapi/config/database.php b/flexiapi/config/database.php index d6b141f..c558606 100644 --- a/flexiapi/config/database.php +++ b/flexiapi/config/database.php @@ -32,7 +32,7 @@ return [ | */ - 'default' => 'mysql', + 'default' => env('DB_CONNECTION', 'mysql'), /* |-------------------------------------------------------------------------- @@ -73,7 +73,7 @@ return [ ], 'pgsql' => [ - 'driver' => 'pgsql', + 'driver' => env('DB_DRIVER', 'pgsql'), 'url' => env('DATABASE_URL'), 'host' => env('DB_HOST', '127.0.0.1'), 'port' => env('DB_PORT', '5432'), diff --git a/flexisip-account-manager.spec b/flexisip-account-manager.spec index 7d1ef06..cefd3d1 100644 --- a/flexisip-account-manager.spec +++ b/flexisip-account-manager.spec @@ -8,7 +8,7 @@ #%define _datadir %{_datarootdir} #%define _docdir %{_datadir}/doc -%define build_number 159 +%define build_number 160 %define var_dir /var/opt/belledonne-communications %define opt_dir /opt/belledonne-communications/share/flexisip-account-manager