url을 맞춰 수정
This commit is contained in:
parent
3153cf0383
commit
cf2b5d4e80
|
|
@ -13,6 +13,11 @@ const getApiBaseUrl = (): string => {
|
||||||
const currentPort = window.location.port;
|
const currentPort = window.location.port;
|
||||||
const protocol = window.location.protocol;
|
const protocol = window.location.protocol;
|
||||||
|
|
||||||
|
// 프로덕션 환경: logistream.kpslp.kr → 백엔드는 같은 도메인 8080 포트
|
||||||
|
if (currentHost === "logistream.kpslp.kr") {
|
||||||
|
return `${protocol}//${currentHost}:8080/api`;
|
||||||
|
}
|
||||||
|
|
||||||
// 프로덕션 환경: v1.vexplor.com → api.vexplor.com
|
// 프로덕션 환경: v1.vexplor.com → api.vexplor.com
|
||||||
if (currentHost === "v1.vexplor.com") {
|
if (currentHost === "v1.vexplor.com") {
|
||||||
return "https://api.vexplor.com/api";
|
return "https://api.vexplor.com/api";
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,11 @@ export function getApiUrl(endpoint: string): string {
|
||||||
if (typeof window !== "undefined") {
|
if (typeof window !== "undefined") {
|
||||||
const hostname = window.location.hostname;
|
const hostname = window.location.hostname;
|
||||||
|
|
||||||
|
// 프로덕션: logistream.kpslp.kr → 백엔드는 같은 도메인 8080 포트
|
||||||
|
if (hostname === "logistream.kpslp.kr") {
|
||||||
|
return `https://logistream.kpslp.kr:8080${endpoint}`;
|
||||||
|
}
|
||||||
|
|
||||||
// 프로덕션: v1.vexplor.com → https://api.vexplor.com
|
// 프로덕션: v1.vexplor.com → https://api.vexplor.com
|
||||||
if (hostname === "v1.vexplor.com") {
|
if (hostname === "v1.vexplor.com") {
|
||||||
return `https://api.vexplor.com${endpoint}`;
|
return `https://api.vexplor.com${endpoint}`;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue