-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove the need for copying config to eZ kernel
- Loading branch information
Showing
6 changed files
with
31 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,25 @@ | ||
<?php | ||
|
||
/** | ||
* File containing the bootstrapping of eZ Publish API for unit test use. | ||
* | ||
* Setups class loading. | ||
* | ||
* @copyright Copyright (C) eZ Systems AS. All rights reserved. | ||
* @license For full copyright and license information view LICENSE file distributed with this source code. | ||
*/ | ||
|
||
$kernelDir = __DIR__ . '/vendor/ezsystems/ezpublish-kernel'; | ||
|
||
// Get global config.php settings | ||
if (!($settings = include(__DIR__ . '/vendor/ezsystems/ezpublish-kernel/config.php'))) { | ||
throw new \RuntimeException('Could not find config.php, please copy config.php-DEVELOPMENT to vendor/ezsystems/ezpublish-kernel/config.php & customize to your needs!'); | ||
if (!file_exists($kernelDir . '/config.php')) { | ||
if (!symlink(__DIR__ . '/config.php-DEVELOPMENT', $kernelDir . '/config.php')) { | ||
throw new \RuntimeException('Could not symlink config.php-DEVELOPMENT to config.php, please copy config.php-DEVELOPMENT to config.php & customize to your needs!'); | ||
} | ||
} | ||
|
||
if (!($settings = include($kernelDir . '/config.php'))) { | ||
throw new \RuntimeException('Could not read config.php, please copy config.php-DEVELOPMENT to config.php & customize to your needs!'); | ||
} | ||
|
||
require_once __DIR__ . '/vendor/autoload.php'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,14 @@ | ||
<?php | ||
/** | ||
* eZ Publish 5.x config.php file. | ||
* | ||
* Returns global application settings | ||
* Usually contain settings needed to setup services needed for ezp startup. | ||
* | ||
* @copyright Copyright (C) eZ Systems AS. All rights reserved. | ||
* @license For full copyright and license information view LICENSE file distributed with this source code. | ||
* @version //autogentag// | ||
* | ||
* @doc Copy this file to config.php to get started! | ||
*/ | ||
|
||
// Required: Settings bellow are runtime settings that needs to be set here, you can | ||
// optionally also override any other setting here. | ||
$kernelDir = __DIR__ . '/vendor/ezsystems/ezpublish-kernel'; | ||
|
||
return array( | ||
// The installation directory | ||
'install_dir' => __DIR__, | ||
'install_dir' => $kernelDir, | ||
|
||
// Path to the containerBuilder.php file used by service container | ||
'container_builder_path' => __DIR__ . '/eZ/Publish/Core/settings/containerBuilder.php', | ||
// The cache directory | ||
'cache_dir' => __DIR__ . '/var/cache', | ||
'container_builder_path' => $kernelDir . '/eZ/Publish/Core/settings/containerBuilder.php', | ||
|
||
// The Legacy Kernel installation directory, detect legacy location | ||
'legacy_dir' => ( | ||
is_dir('./ezpublish_legacy') ? | ||
getcwd() . '/ezpublish_legacy' : | ||
__DIR__ . '/vendor/ezsystems/ezpublish-legacy' | ||
), | ||
'imagemagick_convert_path' => '/usr/bin/convert', | ||
// The cache directory | ||
'cache_dir' => $kernelDir . '/var/cache', | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters