forked from Deiru2k/miracle-tv
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnext.config.js
More file actions
29 lines (28 loc) · 827 Bytes
/
Copy pathnext.config.js
File metadata and controls
29 lines (28 loc) · 827 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
var isDev = process.env.NODE_ENV === "development";
const { i18n } = require("./next-i18next.config");
module.exports = {
i18n,
productionBrowserSourceMaps: true,
distDir: "/dist/client",
publicRuntimeConfig: {
// Will be available on both server and client
isDev: isDev,
apiUrl: process.env.NEXT_PUBLIC_API_URL,
socketPreix: process.env.NEXT_PUBLIC_SOCKET_PREFIX,
mediaUrl: process.env.NEXT_PUBLIC_MEDIA_URL,
},
async rewrites() {
return isDev
? [
{
source: "/streaming/hls/:path*",
destination: "http://localhost:8081/live/:path*", // Proxy to Backend
},
{
source: "/streaming/dash/:path*",
destination: "http://localhost:8081/dash/:path*", // Proxy to Backend
},
]
: [];
},
};