fix docker on different port (#337)

Co-authored-by: Fabian Posenau <fabian@fphome.de>
This commit is contained in:
Fabian Posenau
2023-04-14 10:08:42 +02:00
committed by GitHub
parent 5ba27dca1d
commit 94a1369d64
2 changed files with 3 additions and 2 deletions
+2 -2
View File
@@ -19,10 +19,10 @@ export const githubURL = 'https://api.github.com/repos/cpvalente/ontime/releases
* @description finds server path given the current location, it
* @return {*}
*/
export const calculateServer = () => (import.meta.env.DEV ? `http://localhost:${STATIC_PORT}` : window.location.origin);
export const calculateServer = () => (import.meta.env.DEV ? `http://localhost:${window.location.port}` : window.location.origin);
export const serverURL = calculateServer();
export const websocketUrl = `ws://${window.location.hostname}:${STATIC_PORT}/ws`;
export const websocketUrl = `ws://${window.location.hostname}:${window.location.port}/ws`;
export const eventURL = `${serverURL}/eventdata`;
export const rundownURL = `${serverURL}/events`;