Merge branch 'main' into 'main'

Add env vars to load webui from different paths

See merge request RemixDev/deemix-webui!40
This commit is contained in:
RemixDev 2022-07-29 16:02:14 +00:00
commit f0519e3fc0
2 changed files with 3 additions and 2 deletions

View File

@ -120,6 +120,7 @@ const routes = [
const router = new VueRouter({ const router = new VueRouter({
mode: 'history', mode: 'history',
base: process.env.BASE_URL || '',
routes, routes,
scrollBehavior() { scrollBehavior() {
return { x: 0, y: 0 } return { x: 0, y: 0 }

View File

@ -33,5 +33,5 @@ class CustomSocket extends WebSocket {
} }
} }
} }
const domain = process.env.WEBSOCKET_URL || location.host
export const socket = new CustomSocket((location.protocol === 'https:' ? 'wss://' : 'ws://') + location.host + '/') export const socket = new CustomSocket((location.protocol === 'https:' ? 'wss://' : 'ws://') + domain + '/')