This repository has been archived on 2024-06-14. You can view files and clone it, but cannot push or open issues or pull requests.
icynet-admin/server/proxy.ts
2022-08-29 21:09:28 +03:00

11 lines
318 B
TypeScript

import httpProxy from 'http-proxy';
export const proxy = httpProxy.createProxyServer({
/**
* Get the actual back-end service url from env variables.
* We shouldn't prefix the env variable with NEXT_PUBLIC_* to avoid exposing it to the client.
*/
target: process.env.SERVER_URL,
autoRewrite: false,
});