Skip to content

Commit bd1a014

Browse files
committed
Migrate to PHP config files
1 parent 4c703e1 commit bd1a014

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+557
-282
lines changed

app/config/packages/dev/mailer.php

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;
6+
7+
return static function (ContainerConfigurator $containerConfigurator): void {
8+
$containerConfigurator->extension('framework', [
9+
'mailer' => [
10+
'dsn' => 'null://null',
11+
],
12+
]);
13+
};

app/config/packages/dev/mailer.yaml

Lines changed: 0 additions & 3 deletions
This file was deleted.
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;
6+
7+
return static function (ContainerConfigurator $containerConfigurator): void {
8+
$containerConfigurator->extension('monolog', [
9+
'handlers' => [
10+
'main' => [
11+
'type' => 'stream',
12+
'path' => '%kernel.logs_dir%/%kernel.environment%.log',
13+
'level' => 'debug',
14+
'channels' => [
15+
'!event',
16+
],
17+
],
18+
'console' => [
19+
'type' => 'console',
20+
'process_psr_3_messages' => false,
21+
'channels' => [
22+
'!event',
23+
'!doctrine',
24+
'!console',
25+
],
26+
],
27+
],
28+
]);
29+
};

app/config/packages/dev/monolog.yaml

Lines changed: 0 additions & 11 deletions
This file was deleted.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;
6+
7+
return static function (ContainerConfigurator $containerConfigurator): void {
8+
$containerConfigurator->extension('framework', [
9+
'router' => [
10+
'strict_requirements' => true,
11+
],
12+
]);
13+
};

app/config/packages/dev/routing.yaml

Lines changed: 0 additions & 3 deletions
This file was deleted.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;
6+
7+
return static function (ContainerConfigurator $containerConfigurator): void {
8+
$containerConfigurator->extension('web_profiler', [
9+
'toolbar' => true,
10+
'intercept_redirects' => false,
11+
]);
12+
13+
$containerConfigurator->extension('framework', [
14+
'profiler' => [
15+
'only_exceptions' => false,
16+
],
17+
]);
18+
};

app/config/packages/dev/web_profiler.yaml

Lines changed: 0 additions & 6 deletions
This file was deleted.

app/config/packages/doctrine.php

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;
6+
7+
return static function (ContainerConfigurator $containerConfigurator): void {
8+
$parameters = $containerConfigurator->parameters();
9+
10+
$parameters->set('env(DATABASE_URL)', '');
11+
12+
$containerConfigurator->extension('doctrine', [
13+
'dbal' => [
14+
'url' => '%env(resolve:DATABASE_URL)%',
15+
],
16+
'orm' => [
17+
'naming_strategy' => 'doctrine.orm.naming_strategy.underscore',
18+
'auto_mapping' => true,
19+
'mappings' => [
20+
'App' => [
21+
'is_bundle' => false,
22+
'type' => 'attribute',
23+
'dir' => '%kernel.project_dir%/src/Entity',
24+
'prefix' => 'App\Entity',
25+
'alias' => 'App',
26+
],
27+
],
28+
],
29+
]);
30+
};

app/config/packages/doctrine.yaml

Lines changed: 0 additions & 16 deletions
This file was deleted.

0 commit comments

Comments
 (0)