Skip to content
Snippets Groups Projects
Commit 4815c3cc authored by Greg Fodor's avatar Greg Fodor
Browse files

Add polling loop for build version

parent 94758f29
No related branches found
No related tags found
No related merge requests found
...@@ -40,6 +40,7 @@ ...@@ -40,6 +40,7 @@
"exit.subtitle.closed": "This room is no longer available.", "exit.subtitle.closed": "This room is no longer available.",
"exit.subtitle.full": "This room is full, please try again later.", "exit.subtitle.full": "This room is full, please try again later.",
"exit.subtitle.connect_error": "Unable to connect to this room, please try again later.", "exit.subtitle.connect_error": "Unable to connect to this room, please try again later.",
"exit.subtitle.version_mismatch": "The version you deployed is not available yet. Your browser will refresh in 5 seconds.",
"autoexit.title": "Auto-ending session in ", "autoexit.title": "Auto-ending session in ",
"autoexit.title_units": " seconds", "autoexit.title_units": " seconds",
"autoexit.subtitle": "You have started another session.", "autoexit.subtitle": "You have started another session.",
......
...@@ -432,6 +432,13 @@ const onReady = async () => { ...@@ -432,6 +432,13 @@ const onReady = async () => {
return; return;
} }
if (qs.required_version && qs.required_version !== process.env.BUILD_VERSION) {
remountUI({ roomUnavailableReason: "version_mismatch" });
setTimeout(() => document.location.reload(), 5000);
exitScene();
return;
}
getAvailableVREntryTypes().then(availableVREntryTypes => { getAvailableVREntryTypes().then(availableVREntryTypes => {
if (availableVREntryTypes.gearvr === VR_DEVICE_AVAILABILITY.yes) { if (availableVREntryTypes.gearvr === VR_DEVICE_AVAILABILITY.yes) {
remountUI({ availableVREntryTypes, forcedVREntryType: "gearvr" }); remountUI({ availableVREntryTypes, forcedVREntryType: "gearvr" });
......
...@@ -266,7 +266,8 @@ const config = { ...@@ -266,7 +266,8 @@ const config = {
NODE_ENV: process.env.NODE_ENV, NODE_ENV: process.env.NODE_ENV,
JANUS_SERVER: process.env.JANUS_SERVER, JANUS_SERVER: process.env.JANUS_SERVER,
DEV_RETICULUM_SERVER: process.env.DEV_RETICULUM_SERVER, DEV_RETICULUM_SERVER: process.env.DEV_RETICULUM_SERVER,
ASSET_BUNDLE_SERVER: process.env.ASSET_BUNDLE_SERVER ASSET_BUNDLE_SERVER: process.env.ASSET_BUNDLE_SERVER,
BUILD_VERSION: process.env.BUILD_VERSION
}) })
}) })
] ]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment