Skip to content
Snippets Groups Projects
Commit 4bd094b9 authored by kasperlauge's avatar kasperlauge
Browse files

Made a dockerfile which utilizes caching of npm

parent ce2b8367
No related branches found
No related tags found
No related merge requests found
......@@ -16,19 +16,21 @@ RUN mkdir -p /usr/src && \
make install) && \
rm -rf /usr/src/{bcm2835-1.60,pigpio}
WORKDIR /iot-project
COPY . /iot-project
# Build server
WORKDIR /iot-project/server
COPY ./server/package*.json ./
RUN npm install
COPY ./server ./
RUN npm run clean
RUN npm run build
# Build client
WORKDIR /iot-project/client
COPY ./client/package*.json ./
RUN npm install
COPY ./client ./
RUN npm run build:prod
EXPOSE 8080
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment