mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-06-23 10:18:56 +02:00
Updated recipe of framework bundle.
This commit is contained in:
parent
96acf0d858
commit
7c876b4a9c
3 changed files with 18 additions and 7 deletions
|
@ -15,17 +15,27 @@ class Kernel extends BaseKernel
|
|||
{
|
||||
$container->import('../config/{packages}/*.yaml');
|
||||
$container->import('../config/{packages}/'.$this->environment.'/*.yaml');
|
||||
$container->import('../config/{services}.yaml');
|
||||
$container->import('../config/{services}_'.$this->environment.'.yaml');
|
||||
|
||||
//Add parameter file
|
||||
//Add parameters.yml
|
||||
$container->import('../config/parameters.yaml');
|
||||
|
||||
if (is_file(\dirname(__DIR__).'/config/services.yaml')) {
|
||||
$container->import('../config/{services}.yaml');
|
||||
$container->import('../config/{services}_'.$this->environment.'.yaml');
|
||||
} elseif (is_file($path = \dirname(__DIR__).'/config/services.php')) {
|
||||
(require $path)($container->withPath($path), $this);
|
||||
}
|
||||
}
|
||||
|
||||
protected function configureRoutes(RoutingConfigurator $routes): void
|
||||
{
|
||||
$routes->import('../config/{routes}/'.$this->environment.'/*.yaml');
|
||||
$routes->import('../config/{routes}/*.yaml');
|
||||
$routes->import('../config/{routes}.yaml');
|
||||
|
||||
if (is_file(\dirname(__DIR__).'/config/routes.yaml')) {
|
||||
$routes->import('../config/{routes}.yaml');
|
||||
} elseif (is_file($path = \dirname(__DIR__).'/config/routes.php')) {
|
||||
(require $path)($routes->withPath($path), $this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue