all repos — caroster @ fafa7be8aa12552af5c20cf6f152dce873a60960

[Octree] Group carpool to your event https://caroster.io

🏗 Improve Docker image size
Tim Izzo tim@octree.ch
Wed, 01 Jul 2020 16:10:29 +0200
commit

fafa7be8aa12552af5c20cf6f152dce873a60960

parent

5777ae1c5a025e11e6ed64d476a6ebf645e47c97

2 files changed, 12 insertions(+), 3 deletions(-)

jump to
M DockerfileDockerfile

@@ -1,3 +1,4 @@

+# Build stage FROM strapi/base:12-alpine ARG NPM_REGISTRY=https://npm-8ee.hidora.com/

@@ -5,8 +6,7 @@ ENV NODE_ENV production

WORKDIR /srv/app RUN apk add --no-cache git -RUN npm set registry $NPM_REGISTRY && \ - npm install -g strapi@latest +RUN npm set registry $NPM_REGISTRY ## Install dependencies COPY . /srv/app/

@@ -22,4 +22,12 @@ npm run build && \

mv build ../public && \ cd .. && rm -rf app -CMD ["strapi", "start"] +# Prod stage +FROM strapi/base:12-alpine + +ENV NODE_ENV production +WORKDIR /srv/app + +COPY --from=0 /srv/app . + +CMD ["npm", "start"]
M app/src/containers/CarColumns/index.jsapp/src/containers/CarColumns/index.js

@@ -23,6 +23,7 @@ {

breakpoint: 600, settings: { slidesToShow: 1, + initialSlide: 1, }, }, {