forked from csrdelft/csrdelft.nl
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathphinx.php
More file actions
30 lines (26 loc) · 742 Bytes
/
phinx.php
File metadata and controls
30 lines (26 loc) · 742 Bytes
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
<?php
/**
* Configuratie voor Phinx, verbind met de stek database om daar migraties op te kunnen runnen.
*/
// PHP from Phinx might not have a proper path
set_include_path(get_include_path() . PATH_SEPARATOR . 'lib');
require_once 'defines.defaults.php';
$db_cred = parse_ini_file(ETC_PATH . 'mysql.ini');
return [
'paths' => [
'migrations' => '%%PHINX_CONFIG_DIR%%/db/migrations',
'seeds' => '%%PHINX_CONFIG_DIR%%/db/seeds'
],
'environments' => [
'default_migration_table' => 'phinxlog',
'default_database' => 'stekdb',
'stekdb' => [
'adapter' => 'mysql',
'host' => $db_cred['host'],
'name' => $db_cred['db'],
'user' => $db_cred['user'],
'pass' => $db_cred['pass']
]
],
'version_order' => 'creation'
];