module.config.php 1.97 KB
Newer Older
1
2
3
4
5
<?php

namespace Demo;

return [
6
7
8
    //
    // ATTENTION: config Doctrine à déplacer dans `APP/config/autoload/`.
    //
9
10
11
    'doctrine' => [
        'connection' => [
            'orm_default' => [
12
                'driverClass' => \Doctrine\DBAL\Driver\PDOPgSql\Driver::class,
13
                'params' => [
14
15
16
17
18
19
20
                    'host' => 'db',        //
                    'user' => 'admin',     // cf. docker-compose.yml
                    'password' => 'admin', //
                    'dbname' => 'demo',    //
                    'port' => '5432',
                    'charset' => 'utf8',
                    'driverOptions' => [1002 => 'SET NAMES utf8']
21
22
23
24
                ],
            ],
        ],
    ],
25

26
27
28
    'bjyauthorize'    => [
        'guards'                => [
            'BjyAuthorize\Guard\Controller'         => [
Bertrand Gauthier's avatar
Bertrand Gauthier committed
29
                ['controller' => 'Demo\Controller\Index', 'roles' => 'guest'],
30
31
32
33
34
35
            ],
        ],
    ],
    'router'          => [
        'routes' => [
            'home'        => [
36
                'type'    => 'Literal',
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
                'options' => [
                    'route'    => '/',
                    'defaults' => [
                        'controller' => 'Demo\Controller\Index', // <-- change here
                        'action'     => 'index',
                    ],
                ],
            ],
        ],
    ],
    'service_manager' => [
        'factories' => [

        ],
    ],
    'translator'      => [
        'locale'                    => 'fr_FR', // en_US
        'translation_file_patterns' => [
            [
                'type'     => 'gettext',
                'base_dir' => __DIR__ . '/../language',
                'pattern'  => '%s.mo',
            ],
        ],
    ],
    'controllers'     => [
        'invokables' => [
            'Demo\Controller\Index' => Controller\IndexController::class,
        ],
    ],
    'view_manager'    => [
        'template_path_stack' => [
            __DIR__ . '/../view',
        ],
    ],
];