build utils
This commit is contained in:
11
nginx/Dockerfile
Normal file
11
nginx/Dockerfile
Normal file
@ -0,0 +1,11 @@
|
||||
FROM node:21-alpine as build
|
||||
WORKDIR /app
|
||||
ENV PATH /app/node_modules/.bin:$PATH
|
||||
COPY ./frontend/app .
|
||||
RUN npm ci
|
||||
RUN npm run build
|
||||
|
||||
FROM nginx:1.25.4-alpine
|
||||
COPY --from=build /app/dist /usr/share/nginx/html
|
||||
EXPOSE 80
|
||||
CMD ["nginx", "-g", "daemon off;"]
|
||||
@ -1,6 +1,6 @@
|
||||
server {
|
||||
listen 80;
|
||||
server_name 192.168.1.121;
|
||||
server_name queueful.ollyhearn.ru;
|
||||
location / {
|
||||
proxy_hide_header 'Access-Control-Allow-Origin';
|
||||
add_header 'Access-Control-Allow-Origin' '*' always;
|
||||
@ -25,7 +25,7 @@ server {
|
||||
proxy_hide_header 'Access-Control-Allow-Methods';
|
||||
add_header 'Access-Control-Allow-Methods' '*' always;
|
||||
|
||||
proxy_pass http://api:8000/api/;
|
||||
proxy_pass http://backend:8000;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
|
||||
Reference in New Issue
Block a user