.
This commit is contained in:
parent
ddde35a367
commit
83df3a87fe
@ -26,6 +26,10 @@ RUN cd ./server && yarn install
|
||||
# Si hay un error, mostrarlo en detalle.
|
||||
RUN cd ./server && yarn run build || { echo 'Error during build'; exit 1; }
|
||||
|
||||
# Copiar plantillas
|
||||
RUN mkdir -p /api/dist/server/src/contexts/sales/infrastructure/express/controllers/quotes/reportQuote/reporter/templates/quote/
|
||||
COPY server/src/contexts/sales/infrastructure/express/controllers/quotes/reportQuote/reporter/templates/quote/* /api/dist/server/src/contexts/sales/infrastructure/express/controllers/quotes/reportQuote/reporter/templates/quote
|
||||
|
||||
# FINAL STAGE (Producción)
|
||||
FROM node:lts-iron AS prod
|
||||
|
||||
|
||||
@ -33,7 +33,7 @@ module.exports = {
|
||||
server: {
|
||||
hostname: process.env.HOSTNAME || "127.0.0.1",
|
||||
port: process.env.PORT || 4001,
|
||||
public_url: "",
|
||||
cors_origin: "*",
|
||||
},
|
||||
|
||||
admin: {
|
||||
|
||||
@ -18,6 +18,7 @@ module.exports = {
|
||||
server: {
|
||||
hostname: process.env.HOSTNAME || "127.0.0.1",
|
||||
port: process.env.PORT || 3001,
|
||||
cors_origin: "https://presupuestos.uecko.com",
|
||||
},
|
||||
|
||||
admin: {
|
||||
|
||||
@ -7,6 +7,7 @@ import { configurePassportAuth } from "@/contexts/auth";
|
||||
import morgan from "morgan";
|
||||
import passport from "passport";
|
||||
import path from "path";
|
||||
import { config } from "../../config";
|
||||
import { v1Routes } from "./api/v1";
|
||||
|
||||
//const logger = initLogger(rTracer);
|
||||
@ -26,7 +27,8 @@ app.use(responseTime());
|
||||
// enable CORS - Cross Origin Resource Sharing
|
||||
app.use(
|
||||
cors({
|
||||
origin: "*", //"http://localhost:5173",
|
||||
origin: config.server.cors_origin,
|
||||
methods: "GET,POST,PUT,DELETE",
|
||||
credentials: true,
|
||||
|
||||
exposedHeaders: [
|
||||
|
||||
Loading…
Reference in New Issue
Block a user