mirror of
https://github.com/cinnyapp/cinny.git
synced 2024-12-29 10:56:10 +00:00
1b9216b341
* Use npm ci over install to achive faster and more expectable build results; Split copy package(-lock).json files and ci then to avoid reinstalling dependencies when not needed => Faster build times * Stopp adding wasm type to mime.types, its already there (duplicate): - avoids warning in console - cleans up - might have been missing in past nginx:alpine versions but now exists * Change node tag from alpine and nginx to more specific ones for #260
19 lines
291 B
Docker
19 lines
291 B
Docker
## Builder
|
|
FROM node:17.4.0-alpine3.15 as builder
|
|
|
|
WORKDIR /src
|
|
|
|
COPY package.json package-lock.json /src
|
|
RUN npm ci
|
|
COPY . /src
|
|
RUN npm run build
|
|
|
|
|
|
## App
|
|
FROM nginx:1.21.6-alpine
|
|
|
|
COPY --from=builder /src/dist /app
|
|
|
|
RUN rm -rf /usr/share/nginx/html \
|
|
&& ln -s /app /usr/share/nginx/html
|