尝试构建错误

时间:2016-09-20 07:54:06

标签: php linux netbeans docker dockerfile

我是Docker的新用户,并试图将它用于Mac上的一个带有Netbeans的PHP项目。

我的泊坞文件位于下方。

FROM ubuntu:latest
MAINTAINER "Joe" <joe@fakewebsitefornow.com>
# Install apache, PHP, and supplimentary programs. openssh-server, curl, and lynx-cur are for debugging the container.
RUN apt-get update && apt-get -y upgrade && DEBIAN_FRONTEND=noninteractive apt-get -y install \
    apache2 php7.0 php7.0-mysql libapache2-mod-php7.0 curl lynx-cur

# Enable apache mods.
RUN a2enmod php7.0
RUN a2enmod rewrite

# Update the PHP.ini file, enable <? ?> tags and quieten logging.
RUN sed -i "s/short_open_tag = Off/short_open_tag = On/" /etc/php/7.0/apache2/php.ini
RUN sed -i "s/error_reporting = .*$/error_reporting = E_ERROR | E_WARNING | E_PARSE/" /etc/php/7.0/apache2/php.ini

# Manually set up the apache environment variables
ENV APACHE_RUN_USER www-data
ENV APACHE_RUN_GROUP www-data
ENV APACHE_LOG_DIR /var/log/apache2
ENV APACHE_LOCK_DIR /var/lock/apache2
ENV APACHE_PID_FILE /var/run/apache2.pid

# Expose apache.
EXPOSE 80

# Copy this repo into place.
ADD www /var/www/site

# Update the default apache site with the config we created.
ADD apache-config.conf /etc/apache2/sites-enabled/000-default.conf

# By default start up apache in the foreground, override with /bin/bash for interative.
CMD /usr/sbin/apache2ctl -D FOREGROUND

我使用netbeans 8.2并从那里构建我的Dockerfile。我像这样设置我的目录。

MyWebsite
-- www
-- Dockerfile
-- apache-config.conf

我在尝试构建时遇到以下错误。

java.lang.RuntimeException:文件名&www; www / templates / vendor / symfony / console / Tests / Fixtures / application_renderexception_doublewidth1decorated.txt&#39;太长(> 100字节)

错误之前很多陈述都是这样的..

Sending file Dockerfile
Sending file .DS_Store
Sending file apache-config.conf
Sending file .git/index
Sending file .git/FETCH_HEAD
Sending file .git/config
Sending file .git/HEAD
Sending file www/index.php
Sending file www/compileless.sh
Sending file www/configlocal.php
Sending file www/configdev.php... (shortened for brevity)

不确定它是否应该像这样发送我的网站?

我假设在linux和mac之间有关于文件名规则的事情?问题是我无法轻易更改文件名,因为它是通过composer下载的供应商!

感谢任何帮助,帮助我建立这种形象,我不知道该做什么。

如果您想模拟我的依赖项,请参阅下面的composer.json。

{
    "require": {
        "slim/slim": "^3.0",
        "slim/twig-view": "^2.1",
        "doctrine/orm": "^2.5",
        "components/jquery": "*",
        "components/normalize.css": "*",
        "robloach/component-installer": "*",
        "paragonie/random_compat": "^2.0"
    },
    "autoload": {
        "psr-4": {"app\\":"app","entities\\":"entities"},
        "files": ["lib/utilities.php","lib/security.php"]
    }
}

0 个答案:

没有答案