From e5fdde74e5954c90e8cdc754f2e6b09ed20de0f4 Mon Sep 17 00:00:00 2001 From: rraymondgh Date: Sun, 9 Feb 2025 17:58:56 +0000 Subject: [PATCH] enable use from another device (mobile) and headless server for development --- Taskfile.yml | 2 +- webui/src/environments/environment.ts | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Taskfile.yml b/Taskfile.yml index e4af15f4..cca33cb6 100644 --- a/Taskfile.yml +++ b/Taskfile.yml @@ -120,7 +120,7 @@ tasks: cmds: - npm start -- --host {{.HOST}} --port {{.PORT}} vars: - HOST: localhost + HOST: 0.0.0.0 PORT: 3334 serve-docsite: diff --git a/webui/src/environments/environment.ts b/webui/src/environments/environment.ts index 1ba10ee9..08ba392a 100644 --- a/webui/src/environments/environment.ts +++ b/webui/src/environments/environment.ts @@ -1 +1,2 @@ -export const graphqlEndpoint = "http://localhost:3333/graphql"; +export const graphqlEndpoint = + window.location.protocol + "//" + window.location.hostname + ":3333/graphql";