From f683acf0ae0865cc9ba661f5c4010c495f95cab8 Mon Sep 17 00:00:00 2001 From: Bill Thiede Date: Sat, 14 Mar 2020 15:08:36 -0700 Subject: [PATCH] Build react-slideshow when building photosync into a docker image. --- .dockerignore | 2 ++ Dockerfile | 8 +++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/.dockerignore b/.dockerignore index 2a59b1f..4c93acf 100644 --- a/.dockerignore +++ b/.dockerignore @@ -1,2 +1,4 @@ +Dockerfile target */node_modules +*/yarn.lock diff --git a/Dockerfile b/Dockerfile index 0707d7c..57256aa 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,7 +3,13 @@ COPY ./ /src/ COPY ./dockerfiles/netrc /root/.netrc RUN mkdir /root/.cargo COPY ./dockerfiles/cargo-config /.cargo/config -RUN apt-get update && apt-get install -y strace build-essential clang +RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - +RUN echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list +RUN curl -sL https://deb.nodesource.com/setup_13.x | bash - +RUN apt-get update && apt-get install -y strace build-essential clang nodejs yarn +WORKDIR /src/react-slideshow +RUN yarn install +RUN yarn build WORKDIR /src RUN cargo version && cargo install --path .