【问题标题】:Error when installing eZ Publish安装 eZ Publish 时出错
【发布时间】:2014-06-02 18:27:20
【问题描述】:

当我尝试使用 installation instructions 安装 eZ Publish 时出现错误。

cd /tmp/
git clone https://github.com/ezsystems/ezpublish-community.git

存储库被正确克隆,然后我进入下一步:

cd ezpublish-community/
composer install --prefer-dist

它会安装所需的软件包,然后显示此错误消息:

[...]
Writing lock file
Generating autoload files
Creating the "ezpublish/config/parameters.yml" file
Some parameters are missing. Please provide them.
secret (ThisTokenIsNotSoSecretChangeIt): [...]
locale_fallback (en): 
ezpublish_legacy.default.view_default_layout ('eZDemoBundle::pagelayout.html.twig'): 
PHP Fatal error:  Class 'eZ\Bundle\EzPublishCoreBundle\Kernel' not found in /tmp/ezpublish-community/ezpublish/EzPublishKernel.php on line 37
Script Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::clearCache handling the post-install-cmd event terminated with an exception

composer.json 文件与current one on github 相同。

我在使用 Ubuntu 14.04 和 Debian wheezy (7.5) 时遇到了这个问题。

更新

这是一个解决方案,但需要注意的是,它将安装 eZ Publish 的开发版本(请参阅下面 jeromegamez 的答案)。

我可以通过增加 PHP 的 memory_limit 参数来安装 eZ Publish:

这不起作用(我不知道为什么,我不在乎):

php -d memory_limit="1G" ./composer.phar install --prefer-dist

所以我更改了/etc/php5/cli/php.ini文件:

; Maximum amount of memory a script may consume (128MB)
; http://php.net/memory-limit
;memory_limit = 128M
; New
memory_limit = 1G

安装完美。

【问题讨论】:

  • @RajatModi :不,我仍然有同样的问题,即使我开始全新安装。
  • @RajatModi :我找到了解决方案,请查看我的问题的更新。

标签: composer-php ezpublish


【解决方案1】:

github 上的 master 分支包含 eZ Publish 的前沿,可能包含尚未检测到或新引入的错误。您描述的错误可能就是其中之一,因为就在片刻之前(您的帖子发布日期后 10 天),我执行了与您描述的相同的步骤,并且一切正常。

如果您不需要参与 eZ Publish 的开发,而是想在 eZ Publish 中四处看看或根据自己的需要创建一个基于 eZ Publish 的新项目,我建议您从 @987654321 下载一个版本@ 并关注installation instructions from the official documentation

另一个不错的简单方法是使用

composer create-project ezsystems/ezpublish-community

这将使您设置最新版本,而无需手动克隆存储库或提取档案。

当前的稳定版本是 2014.03,但 eZ Systems 目前正在准备一个新的(以及更多功能完整和稳定的)版本 (2014.05),因此在它发布之前可能值得开始或继续 eZ 冒险.

如果您还有其他问题,请随时提问!

【讨论】:

  • 非常感谢,不知道github仓库不是stable分支。
  • 实际上问题中的错误是由于memory_limit参数太低造成的。但是你对官方文档的解释是完美的。再次感谢。
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2015-12-09
  • 1970-01-01
  • 1970-01-01
  • 2018-05-04
  • 2018-02-03
  • 1970-01-01
相关资源
最近更新 更多