From 2db03a163d1d4ba43cabbb545b76df301efe2f0c Mon Sep 17 00:00:00 2001 From: Alejandro Celaya Date: Fri, 7 Dec 2018 20:42:58 +0100 Subject: [PATCH] Updated how config is imported and merged, so that it includes any config file in json format from config/params dir --- CHANGELOG.md | 2 +- config/config.php | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e3ff628d..8e4e5ec3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,7 +12,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), #### Changed -* *Nothing* +* [#312](https://github.com/shlinkio/shlink/issues/312) Now all config files both in `php` and `json` format are loaded from `config/params` folder, easing users to provided customizations to docker image. #### Deprecated diff --git a/config/config.php b/config/config.php index ce0950c3..1c87f66e 100644 --- a/config/config.php +++ b/config/config.php @@ -19,5 +19,6 @@ return (new ConfigAggregator\ConfigAggregator([ CLI\ConfigProvider::class, Installer\ConfigProvider::class, Rest\ConfigProvider::class, - new ConfigAggregator\ZendConfigProvider('config/{autoload/{{,*.}global,{,*.}local},params/generated_config}.php'), + new ConfigAggregator\PhpFileProvider('config/autoload/{{,*.}global,{,*.}local}.php'), + new ConfigAggregator\ZendConfigProvider('config/params/{generated_config.php,*.config.{php,json}}'), ], 'data/cache/app_config.php'))->getMergedConfig();