From c6e78817637e6e4953a17272b8789371c828d295 Mon Sep 17 00:00:00 2001 From: FVolral Date: Fri, 24 Sep 2021 19:49:30 +0200 Subject: [PATCH] FIX: Docker-compose file and Dockerfile Fix #18816 : During the build of the docker-compose `web` service, in the `Dockerfile` There is a command which attemps to modify `/etc/hosts`. On my system This file is Read-only. Using the `extra_hosts` parameter in `docker-compose.yml` instead fix the problem. --- build/docker/Dockerfile | 1 - build/docker/docker-compose.yml | 2 ++ 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/build/docker/Dockerfile b/build/docker/Dockerfile index dca74e9e720..eb8e3ade6dc 100644 --- a/build/docker/Dockerfile +++ b/build/docker/Dockerfile @@ -57,7 +57,6 @@ RUN echo "host mail" >> /etc/msmtprc RUN echo "from local@localdomain.com" >> /etc/msmtprc RUN echo "domain localhost.localdomain" >> /etc/msmtprc RUN echo "sendmail_path=/usr/bin/msmtp -t" >> /usr/local/etc/php/conf.d/php-sendmail.ini -RUN echo "localhost localhost.localdomain" >> /etc/hosts EXPOSE 80 diff --git a/build/docker/docker-compose.yml b/build/docker/docker-compose.yml index 2167f069f25..b72118de5fb 100644 --- a/build/docker/docker-compose.yml +++ b/build/docker/docker-compose.yml @@ -46,6 +46,8 @@ services: networks: - internal-pod - external-pod + extra_hosts: + - "localhost.localdomain:127.0.0.1" mail: image: maildev/maildev