Skip to content

Commit 7eaf1d5

Browse files
author
Ashley Baldwin-Hunter
committed
Merge pull request #14 from codeclimate/abh-update-Dockerfile
Update dockerfile to copy package.json before running npm install
2 parents d761d0a + 0eb3890 commit 7eaf1d5

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

Diff for: Dockerfile

+7-6
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,18 @@ FROM node
22

33
MAINTAINER Michael R. Bernstein
44

5-
RUN useradd -u 9000 -r -s /bin/false app
5+
WORKDIR /usr/src/app/
6+
7+
COPY engine.json /
8+
COPY package.json /usr/src/app/
69

710
ENV NODE_ENV production
811

912
RUN npm install
1013

11-
WORKDIR /code
12-
COPY . /usr/src/app
13-
COPY engine.json /
14-
14+
RUN useradd -u 9000 -r -s /bin/false app
1515
USER app
16-
VOLUME /code
16+
17+
COPY . /usr/src/app
1718

1819
CMD ["/usr/src/app/bin/fixme"]

0 commit comments

Comments
 (0)