Vylepseni SSR, pridani meta informaci, zatim dost WIP

This commit is contained in:
Michal Kváček
2023-11-28 11:35:53 +01:00
parent 86605ad53e
commit 11cc6ad107
28 changed files with 371 additions and 403 deletions
+17 -15
View File
@@ -2,26 +2,28 @@
FROM node:20-alpine as develop-stage
WORKDIR /app
COPY package*.json ./
RUN yarn global add @quasar/cli && yarn --production=false
RUN yarn global add @quasar/cli
COPY package.json yarn.lock ./
RUN yarn --production=false
RUN npx update-browserslist-db@latest
COPY . .
# build stage
FROM develop-stage as build-stage
#ARG API_URL
#ENV VUE_API_URL $API_URL
RUN yarn --production=false
RUN quasar build -m ssr
# production stage
#FROM nginx:1.25-alpine as production-stage
#COPY conf/nginx.conf /etc/nginx/nginx.conf
#COPY --from=build-stage /app/dist/spa /app/html
#EXPOSE 80
#
#CMD ["nginx", "-g", "daemon off;"]
FROM node:20-alpine as production-stage
FROM keymetrics/pm2:latest-alpine as production-stage
ENV NODE_ENV production
EXPOSE 3000
WORKDIR /app
COPY process.yml /app
COPY --from=build-stage /app/dict/ssr/package.json /app
RUN yarn global add pm2 && yarn && yarn cache clean
COPY --from=build-stage /app/dist/ssr /app
CMD ["pm2-runtime", "/app/process.yml"]