[fix] Build deps and flower version
Fixes taken from the repo issues to enable building the frontend and the last known compatible flower version
This commit is contained in:
parent
59adb23a90
commit
983ce03fc8
@ -112,7 +112,7 @@ services:
|
||||
# You also have to change the flower command
|
||||
|
||||
flower:
|
||||
image: mher/flower
|
||||
image: mher/flower:0.9.7
|
||||
networks:
|
||||
- ${TRAEFIK_PUBLIC_NETWORK?Variable not set}
|
||||
- default
|
||||
|
@ -1,14 +1,23 @@
|
||||
# Stage 0, "build-stage", based on Node.js, to build and compile the frontend
|
||||
FROM tiangolo/node-frontend:10 as build-stage
|
||||
FROM node:16 as build-stage-1
|
||||
|
||||
# I dont know, it this installation required for you, you might delete them
|
||||
RUN apt-get update && apt-get install -y wget --no-install-recommends \
|
||||
&& wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add - \
|
||||
&& sh -c 'echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list' \
|
||||
&& apt-get update \
|
||||
&& apt-get install -y google-chrome-unstable fonts-ipafont-gothic fonts-wqy-zenhei fonts-thai-tlwg fonts-kacst fonts-freefont-ttf \
|
||||
--no-install-recommends \
|
||||
&& rm -rf /var/lib/apt/lists/* \
|
||||
&& apt-get purge --auto-remove -y curl \
|
||||
&& rm -rf /src/*.deb
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY package*.json /app/
|
||||
COPY ./ /app/
|
||||
|
||||
RUN npm install
|
||||
|
||||
COPY ./ /app/
|
||||
|
||||
ARG FRONTEND_ENV=production
|
||||
|
||||
ENV VUE_APP_ENV=${FRONTEND_ENV}
|
||||
@ -18,11 +27,9 @@ RUN npm run test:unit
|
||||
|
||||
RUN npm run build
|
||||
|
||||
|
||||
# Stage 1, based on Nginx, to have only the compiled app, ready for production with Nginx
|
||||
FROM nginx:1.15
|
||||
|
||||
COPY --from=build-stage /app/dist/ /usr/share/nginx/html
|
||||
|
||||
COPY --from=build-stage /nginx.conf /etc/nginx/conf.d/default.conf
|
||||
COPY --from=build-stage-1 /app/dist/ /usr/share/nginx/html
|
||||
COPY ./nginx.conf /etc/nginx/conf.d/default.conf
|
||||
COPY ./nginx-backend-not-found.conf /etc/nginx/extra-conf.d/backend-not-found.conf
|
||||
|
11
frontend/nginx.conf
Normal file
11
frontend/nginx.conf
Normal file
@ -0,0 +1,11 @@
|
||||
server {
|
||||
listen 80;
|
||||
|
||||
location / {
|
||||
root /usr/share/nginx/html;
|
||||
index index.html index.htm;
|
||||
try_files $uri $uri/ /index.html =404;
|
||||
}
|
||||
|
||||
include /etc/nginx/extra-conf.d/*.conf;
|
||||
}
|
Loading…
Reference in New Issue
Block a user