Skip to content

Commit c028f1b

Browse files
author
Simen Daehlin
committed
chore(dockerfile.liquid): changed start to develop
1 parent 68c266a commit c028f1b

1 file changed

Lines changed: 11 additions & 12 deletions

File tree

templates/Dockerfile.liquid

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,32 +5,31 @@ ARG NODE_ENV=development
55
ENV NODE_ENV=${NODE_ENV}
66
RUN addgroup -g 1001 strapi && adduser -u 1001 -G strapi -s /bin/sh -D strapi
77

8-
WORKDIR /opt/
9-
{%- if packageManager == "yarn" %}
10-
COPY package.json yarn.lock ./
8+
WORKDIR /opt/{%- if packageManager == "yarn" %}
9+
COPY package.json yarn.lock ./
1110
{%- else %}
12-
COPY package.json package-lock.json ./
11+
COPY package.json package-lock.json ./
1312
{% endif %}
1413
ENV PATH /opt/node_modules/.bin:$PATH
1514
RUN chown -R strapi:strapi /opt/
1615
USER strapi{%- if packageManager == "yarn" %}
17-
COPY package.json yarn.lock ./
18-
RUN yarn config set network-timeout 600000 -g && yarn install --production
16+
COPY package.json yarn.lock ./
17+
RUN yarn config set network-timeout 600000 -g && yarn install --production
1918
{%- else %}
20-
COPY package.json package-lock.json ./
21-
RUN npm config set network-timeout 600000 -g && npm install --only=production
19+
COPY package.json package-lock.json ./
20+
RUN npm config set network-timeout 600000 -g && npm install --only=production
2221
{%- endif %}
2322

2423
WORKDIR /opt/app
2524
COPY . .
2625
{%- if packageManager == "yarn" %}
27-
RUN ["yarn", "build"]
26+
RUN ["yarn", "build"]
2827
{%- else %}
29-
RUN ["npm", "run","build"]
28+
RUN ["npm", "run","build"]
3029
{%- endif %}
3130
EXPOSE 1337
3231
{%- if packageManager == "yarn" %}
33-
CMD ["yarn", "start"]
32+
CMD ["yarn", "develop"]
3433
{%- else %}
35-
CMD ["npm", "run","develop"]
34+
CMD ["npm", "run","develop"]
3635
{% endif %}

0 commit comments

Comments
 (0)