mirror of
https://github.com/Paris-est-Ludique/intranet.git
synced 2025-06-08 08:34:20 +02:00
Fix api url in prod bug
This commit is contained in:
parent
003ea65979
commit
02be480cca
@ -41,7 +41,9 @@
|
||||
"scripts": {
|
||||
"dev": "yarn dev:build && nodemon ./public/server",
|
||||
"dev:build": "cross-env NODE_ENV=development webpack --config ./webpack/server.config.ts",
|
||||
"local-start": "cross-env INTRANET_HOST=localhost node ./public/server",
|
||||
"start": "node ./public/server",
|
||||
"local-build": "cross-env INTRANET_HOST=localhost run-s build:*",
|
||||
"build": "run-s build:*",
|
||||
"build:server": "cross-env NODE_ENV=production webpack --config ./webpack/server.config.ts",
|
||||
"build:client": "cross-env NODE_ENV=production webpack --config ./webpack/client.config.ts",
|
||||
|
@ -1,11 +1,8 @@
|
||||
const PORT = 4000
|
||||
const HOST_LOCALLY = true
|
||||
const HOST = process.env.INTRANET_HOST || "fo.parisestludique.fr"
|
||||
|
||||
export default {
|
||||
PORT,
|
||||
HOST: HOST_LOCALLY ? "localhost" : "fo.parisestludique.fr",
|
||||
API_URL:
|
||||
__SERVER__ || HOST_LOCALLY
|
||||
? `http://localhost:${PORT}`
|
||||
: `http://fo.parisestludique.fr:${PORT}`,
|
||||
HOST: "0.0.0.0",
|
||||
API_URL: `http://${HOST}:${PORT}`,
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user