From d13d452b426324c17ccd1e740f7a494aba5fd99a Mon Sep 17 00:00:00 2001 From: Ben Best Date: Thu, 18 Jun 2020 17:41:17 -0700 Subject: [PATCH] nginx entrypoint: /docker-start.sh --- docker-compose.yml | 1 + nginx/Dockerfile | 7 +------ nginx/docker-start.sh | 6 ++++++ 3 files changed, 8 insertions(+), 6 deletions(-) create mode 100644 nginx/docker-start.sh diff --git a/docker-compose.yml b/docker-compose.yml index 055ac69..2925e86 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -157,6 +157,7 @@ services: build: ./nginx volumes: - share:/share + entrypoint: /docker-start.sh restart: unless-stopped environment: VIRTUAL_HOST: www.$HOST diff --git a/nginx/Dockerfile b/nginx/Dockerfile index e87f6d9..fa64c21 100644 --- a/nginx/Dockerfile +++ b/nginx/Dockerfile @@ -1,8 +1,3 @@ FROM nginx:stable -# install infographic site from Github -RUN apt-get update; apt-get --assume-yes install git -RUN mkdir /share/github && cd /share/github && \ - git clone https://github.com/marinebon/iea-ne_info.git \ - mv /usr/share/nginx/html /usr/share/nginx/html_0 \ - ln -s iea-ne_info /usr/share/nginx/html +COPY docker-start.sh /docker-start.sh diff --git a/nginx/docker-start.sh b/nginx/docker-start.sh new file mode 100644 index 0000000..aa316f8 --- /dev/null +++ b/nginx/docker-start.sh @@ -0,0 +1,6 @@ +# install infographic site from Github +RUN apt-get update; apt-get --assume-yes install git +RUN mkdir /share/github && cd /share/github && \ + git clone https://github.com/marinebon/iea-ne_info.git \ + mv /usr/share/nginx/html /usr/share/nginx/html_0 \ + ln -s iea-ne_info /usr/share/nginx/html \ No newline at end of file