From 3a84853aa47a18870c90cd7071fa2c22c82db523 Mon Sep 17 00:00:00 2001 From: Igor WITZ <igor.witz@etu.utc.fr> Date: Sun, 14 Oct 2018 23:54:35 +0200 Subject: [PATCH] =?UTF-8?q?R=C3=A9duction=20du=20nombre=20de=20commandes?= =?UTF-8?q?=20ex=C3=A9cut=C3=A9es=20en=20root,=20suppression=20des=20comma?= =?UTF-8?q?ndes=20cd?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pica-etherpad/Dockerfile | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/pica-etherpad/Dockerfile b/pica-etherpad/Dockerfile index 8f23c316..bc2ce310 100644 --- a/pica-etherpad/Dockerfile +++ b/pica-etherpad/Dockerfile @@ -22,18 +22,21 @@ RUN apt-get update && \ pkg-config \ python \ unzip && \ - curl -SL https://github.com/ether/etherpad-lite/archive/${ETHERPAD_VERSION}.zip > etherpad.zip && \ + mkdir -p /opt/etherpad-lite && \ + chown -R node /opt/etherpad-lite + +USER node +WORKDIR /opt/etherpad-lite +RUN curl -SL https://github.com/ether/etherpad-lite/archive/${ETHERPAD_VERSION}.zip > etherpad.zip && \ unzip etherpad && \ rm -Rf etherpad.zip etherpad-lite-${ETHERPAD_VERSION}/.git && \ - mv etherpad-lite-${ETHERPAD_VERSION} /opt/etherpad-lite && \ - mkdir -p /opt/etherpad-lite/src/templates && \ - mkdir -p /opt/etherpad-lite/static && \ - cd /opt/etherpad-lite/src/templates && \ - git clone https://framagit.org/DeBugs/picasoft-etherpad-landing-page.git && \ - cd ./picasoft-etherpad-landing-page/ && \ - git checkout ${ETHERPAD_LANDING_PAGE_VERSION} && \ - cp ./index.html ../index.html && \ - cp ./static/* ../../static/ -r + mv etherpad-lite-${ETHERPAD_VERSION}/* . && \ + mkdir -p src/templates && \ + mkdir -p static && \ + git clone https://framagit.org/DeBugs/picasoft-etherpad-landing-page.git src/templates/picasoft-etherpad-landing-page && \ + git --git-dir=src/templates/picasoft-etherpad-landing-page/.git checkout ${ETHERPAD_LANDING_PAGE_VERSION} && \ + cp src/templates/picasoft-etherpad-landing-page/index.html src/templates/index.html && \ + cp src/templates/picasoft-etherpad-landing-page/static/* static/ -r # construction de l'image finale -- GitLab