2016-08-14 10:09:23 +03:00
|
|
|
#!/usr/bin/env php
|
|
|
|
<?php
|
2018-09-16 19:47:42 +03:00
|
|
|
declare(strict_types=1);
|
2017-12-28 17:52:10 +03:00
|
|
|
|
2018-09-29 10:52:32 +03:00
|
|
|
use Shlinkio\Shlink\Installer\Factory\InstallApplicationFactory;
|
|
|
|
use Shlinkio\Shlink\Installer\Config\Plugin\DatabaseConfigCustomizer;
|
2016-08-19 16:50:08 +03:00
|
|
|
use Symfony\Component\Console\Application;
|
2017-07-05 21:04:44 +03:00
|
|
|
use Symfony\Component\Filesystem\Filesystem;
|
2017-07-22 14:41:41 +03:00
|
|
|
use Zend\ServiceManager\AbstractFactory\ConfigAbstractFactory;
|
2017-07-05 21:04:44 +03:00
|
|
|
use Zend\ServiceManager\Factory\InvokableFactory;
|
2017-07-05 19:12:03 +03:00
|
|
|
use Zend\ServiceManager\ServiceManager;
|
2016-08-14 11:30:43 +03:00
|
|
|
|
2016-08-19 16:50:08 +03:00
|
|
|
chdir(dirname(__DIR__));
|
|
|
|
|
|
|
|
require __DIR__ . '/../vendor/autoload.php';
|
|
|
|
|
2017-07-22 14:41:41 +03:00
|
|
|
$container = new ServiceManager([
|
|
|
|
'factories' => [
|
|
|
|
Application::class => InstallApplicationFactory::class,
|
|
|
|
Filesystem::class => InvokableFactory::class,
|
|
|
|
],
|
|
|
|
'services' => [
|
|
|
|
'config' => [
|
|
|
|
ConfigAbstractFactory::class => [
|
2017-12-31 19:18:54 +03:00
|
|
|
DatabaseConfigCustomizer::class => [Filesystem::class]
|
2017-07-22 14:41:41 +03:00
|
|
|
],
|
|
|
|
],
|
|
|
|
],
|
|
|
|
]);
|
2017-07-05 19:12:03 +03:00
|
|
|
$container->build(Application::class)->run();
|