forked from DASPRiD/container-interop-doctrine
/
minimal-config.php
31 lines (30 loc) · 974 Bytes
/
minimal-config.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
<?php
return [
'doctrine' => [
'connection' => [
'orm_default' => [
'params' => [
'url' => 'mysql://user:password@localhost/database',
],
],
],
'driver' => [
'orm_default' => [
'class' => \Doctrine\Common\Persistence\Mapping\Driver\MappingDriverChain::class,
'drivers' => [
'My\Entity' => 'my_entity',
],
],
'my_entity' => [
'class' => \Doctrine\ORM\Mapping\Driver\XmlDriver::class,
'cache' => 'array',
'paths' => __DIR__ . '/doctrine',
],
],
],
];
/**
* switch out the user and password with the correct connection string
* note that the my_entity driver you specified is looking for entities written in xml files
* for entities written in php use the Annotation Driver (see full config)
*/