Laravel Homestead的SULU CMS安装错误 [英] SULU CMS installation errors with Laravel Homestead

查看:123
本文介绍了Laravel Homestead的SULU CMS安装错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

遵循此文档 http://docs.sulu.io/zh_cn/latest/book/getting-started.html 在安装过程结束时出现此错误:

Follow this document http://docs.sulu.io/en/latest/book/getting-started.html at the end of installation process I got this error:

Target: cache

cache:clear  ({"--no-optional-warmers":true,"--no-debug":true,"--no-interaction":true})


             // Clearing the admin cache for the dev environment with debug true                                            



      [Symfony\Component\Filesystem\Exception\IOException]                                  
      Failed to remove directory "/home/vagrant/Code/sulu/var/cache/admin/de~/doctrine": .  


    sulu:build [-D|--nodeps] [--destroy] [-h|--help] [-q|--quiet] [-v|vv|vvv|--verbose] [-V|--version] [--ansi] [--no-ansi] [-n|--no-interaction] [-s|--shell] [--process-isolation] [-e|--env ENV] [--no-debug] [--] <command> [<target>]

在我尝试使用此方法设置文件权限之前:

Before that I was trying to set up file permissions with this:

HTTPDUSER=`ps axo user,comm | grep -E '[a]pache|[h]ttpd|[_]www|[w]ww-data|[n]ginx' | grep -v root | head -1 | cut -d\  -f1`
sudo setfacl -R -m u:"$HTTPDUSER":rwX -m u:`whoami`:rwX var/cache var/logs var/uploads var/uploads/* web/uploads web/uploads/* var/indexes var/sessions
sudo setfacl -dR -m u:"$HTTPDUSER":rwX -m u:`whoami`:rwX var/cache var/logs var/uploads var/uploads/* web/uploads web/uploads/* var/indexes var/sessions

,并且还存在以下错误:

and also had these errors:

setfacl: web/uploads: Operation not supported
setfacl: web/uploads/media: Operation not supported
setfacl: web/uploads/media: Operation not supported

我的主机操作系统:Ubuntu 16.04 流浪汉:v.1.9.3 虚拟盒子:v.5 宅基地:5.2.1版

My host OS : Ubuntu 16.04 Vagrant : v.1.9.3 VirtualBox : v.5 Homestead: v.5.2.1

有人成功通过Homestead成功安装了Sulu CMS吗? 有什么选择可以解决我的这些问题? Sulu CMS看起来非常有前途,但不幸的是,我仍然无法尝试多次在本地安装它.

Does anyone have successful installation Sulu CMS with Homestead? What is the option to solve these my issues? Sulu CMS looks very promising but unfortunately I could not install it locally still with many attempts.

更新 在发表Daniel的评论后,我尝试了其他方法来安装Sulu,但在安装结束时再次出现错误: 执行建造者 ==================

UPDATE After comment of Daniel I've tried other way to install Sulu but again got error at the very end of installation: Executing builders ==================

Target: cache

cache:clear  ({"--no-optional-warmers":true,"--no-debug":true,"--no-interaction":true})


             // Clearing the admin cache for the dev environment with debug true                                            



      [Symfony\Component\Filesystem\Exception\IOException]                                     
      Failed to remove directory "/home/vagrant/Code/sulu/app/cache/admin/de~/annotations": .  

在浏览器中打开test.app我看到此错误: 致命错误:未捕获 Symfony \ Component \ Debug \ Exception \ FatalThrowableError:在/home/vagrant/Code/sulu/vendor/sulu/sulu/src/Sulu/Bundle/WebsiteBundle/Twig/Content/ContentPathTwigExtension中调用成员函数getLocale()上的null.第70行的php Symfony \ Component \ Debug \ Exception \ FatalThrowableError:在/home/vagrant/Code/sulu/vendor/sulu/sulu/src/Sulu/Bundle/WebsiteBundle/Twig/Content/ContentPathTwigExtension中的null上调用成员函数getLocale().第70行的php

Opened test.app in browser I see this error: Fatal error: Uncaught Symfony\Component\Debug\Exception\FatalThrowableError: Call to a member function getLocale() on null in /home/vagrant/Code/sulu/vendor/sulu/sulu/src/Sulu/Bundle/WebsiteBundle/Twig/Content/ContentPathTwigExtension.php on line 70 Symfony\Component\Debug\Exception\FatalThrowableError: Call to a member function getLocale() on null in /home/vagrant/Code/sulu/vendor/sulu/sulu/src/Sulu/Bundle/WebsiteBundle/Twig/Content/ContentPathTwigExtension.php on line 70

试图手动删除缓存文件夹-同样的错误. 所有控制台命令都可以正常工作. 有什么想法吗?

Tried to delete cache folders manually - the same error. All console commands work fine. Any ideas?

P.S.我在Homestead下安装其他基于Symfony的应用程序方面有丰富的经验,并且一切基本顺利(Sylius,eZ等).所以我很惊讶...

P.S. I have a good experience of installation other Symfony-based applications under Homestead and all went smooth basically (Sylius, eZ etc.). So I am very surprised....

推荐答案

要解决此问题,您需要从主机上删除此文件夹,因为它是先前尝试设置的过程中的人工产物,并且位于由不再存在的全能实体创建的上帝模式.

To get around this, you need to remove this folder from the host machine, because it's an artifact from the previous process of trying to set things up and it's in god-mode, created by a no-longer existing almighty entity.

  • 无用的销毁(需要释放文件系统锁)
  • 删除主机上的文件夹:rm -rf .../sulu/app/cache/admin
  • 类型:文件夹绑定中的nfs
  • 无所事事

然后应该可以工作,最近又遇到了同样的问题.

Should work then, encountered this same problem recently.

如果您使用的是改进的Homestead ,使用内置的"sulu"项目类型进行不错的Nginx自动设置:

If you're using Homestead Improved, use the built-in "sulu" project type for a decent Nginx auto-setup:

sites:
    - map: homestead.app
      to: /home/vagrant/Code/Project/web
      type: sulu

这篇关于Laravel Homestead的SULU CMS安装错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆