Added support for Mysql SSL connection

This commit is contained in:
Frederic Guillot
2016-05-06 19:19:05 -04:00
parent 72dcb6fc9b
commit 400e230881
9 changed files with 106 additions and 58 deletions

View File

@@ -10,6 +10,13 @@ use PicoDb\Database;
class DatabaseProvider implements ServiceProviderInterface
{
/**
* Register provider
*
* @access public
* @param Container $container
* @return Container
*/
public function register(Container $container)
{
$container['db'] = $this->getInstance();
@@ -83,6 +90,9 @@ class DatabaseProvider implements ServiceProviderInterface
'database' => DB_NAME,
'charset' => 'utf8',
'port' => DB_PORT,
'ssl_key' => DB_SSL_KEY,
'ssl_ca' => DB_SSL_CA,
'ssl_cert' => DB_SSL_CERT,
));
}