From 9d870cbc7fbbb1b0b0245eee0dcff76f8f14c785 Mon Sep 17 00:00:00 2001 From: root Date: Wed, 1 Nov 2017 17:27:07 +0100 Subject: [PATCH] on tourne sans root, quotes --- Dockerfile | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/Dockerfile b/Dockerfile index b4bb663..8ebe1e5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,16 +1,21 @@ -FROM php:apache +FROM "php:apache" -RUN apt-get update && \ +RUN sed -i'' 's/^Listen 80$/Listen 8080/' "/etc/apache2/ports.conf" && \ + sed -i'' 's/^$//' '/etc/apache2/sites-enabled/000-default.conf' && \ + apt-get update && \ apt-get -y install libpng12-dev && \ docker-php-ext-install gd && \ apt-get clean all && \ a2enmod headers && \ - rm -rf /usr/share/doc/* \ - /var/cache/* \ - /var/lib/apt/lists/* + rm -rf "/usr/share/doc/*" \ + "/var/cache/*" \ + "/var/lib/apt/lists/*" \ + "/var/www/html" -COPY src/ /var/www/html/ -RUN chown -R www-data:www-data /var/www/html/ +COPY "src" "/var/www/html" +RUN chown -R "www-data":"www-data" "/var/www/html/" + +USER "www-data" HEALTHCHECK --interval=10s \ - CMD curl --fail "http://localhost" || exit 1 \ No newline at end of file + CMD curl --fail "http://localhost:8080" || exit 1