Phalcon-compose和Docker Toolboxnetworking服务器没有看到任何文件

我的操作系统是Windows 7,我正在使用Docker Toolbox。 我按照这个教程,但是当我试图打开网页时,我的浏览器说它无法build立连接。

variables.env(其余是默认值):

# Application WEB_DOCUMENT_ROOT=/project/public WEB_ALIAS_DOMAIN=localhost APPLICATION_CACHE=/project/cache APPLICATION_LOGS=/project/logs # production | development | staging | testing APPLICATION_ENV=development 

主机:

 # Copyright (c) 1993-2009 Microsoft Corp. # # This is a sample HOSTS file used by Microsoft TCP/IP for Windows. # # This file contains the mappings of IP addresses to host names. Each # entry should be kept on an individual line. The IP address should # be placed in the first column followed by the corresponding host name. # The IP address and the host name should be separated by at least one # space. # # Additionally, comments (such as these) may be inserted on individual # lines or following the machine name denoted by a '#' symbol. # # For example: # # 102.54.94.97 rhino.acme.com # source server # 38.25.63.10 x.acme.com # x client host # localhost name resolution is handled within DNS itself. # 127.0.0.1 localhost # ::1 localhost 127.0.0.1 localhost 

然后我发现有一个名为Kitematic的程序已经安装了Docker Tools,所以我打开它并看到了所有的容器。 我去了我的networking服务器“wildlife_app_1”,看到一个控制台,里面有一个警告:

 [WARNING] WEB_DOCUMENT_ROOT does not exists with path "/project/public"! 

有一个叫做“exec”的button,它允许打开一个容器的terminal,所以我打开它,发现“/ project”中实际上没有“public”这样的目录。

有谁知道如何解决这个问题? 提前致谢!

您必须在hosts文件中使用您的主机(本地机器IP),例如。 192.168.1.129 。 注意:这里以192.168.1.129 IP地址为例。

您通常可以使用命令提示符或terminal快速查找信息。 在Windows中,您可以打开“开始”菜单,search命令提示符,然后按Enter键。 然后在出现的命令提示符下键入ipconfig ,然后按Enter键,您将很快find要查找的内容。

在这里输入图像说明

以下是解决scheme,而不pipe怎么说都是一种解决方法。 我已经改变了“。” 点击configuration文件中的项目目录的绝对path。

之前:

  - ./application:/project - ./cache:/project/cache - ./logs:/project/logs 

后:

  - C:/Users/Dmitriy/Desktop/projects/Wildlife/application:/project - C:/Users/Dmitriy/Desktop/projects/Wildlife/cache:/project/cache - C:/Users/Dmitriy/Desktop/projects/Wildlife/logs:/project/logs 

它现在起作用了。