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

Fixes to support local reticulum

parent 89abbc1a
No related branches found
No related tags found
No related merge requests found
#!/usr/bin/env bash
if [ ! -e ../reticulum ]; then
echo "This script assumes reticulum is checked out in a sibling to this folder."
fi
rm -rf ../reticulum/priv/static ; GENERATE_SMOKE_TESTS=true BASE_ASSETS_PATH=https://hubs.local:4000/ yarn build -- --output-path ../reticulum/priv/static
#!/usr/bin/env bash
BASE_ASSETS_PATH=https://hubs.local:8080/ DEV_RETICULUM_SERVER=hubs.local:4000 yarn start
...@@ -85,7 +85,7 @@ class HubCreatePanel extends Component { ...@@ -85,7 +85,7 @@ class HubCreatePanel extends Component {
const hub = await res.json(); const hub = await res.json();
if (process.env.NODE_ENV === "production") { if (process.env.NODE_ENV === "production" || document.location.host === process.env.DEV_RETICULUM_SERVER) {
document.location = hub.url; document.location = hub.url;
} else { } else {
document.location = `/hub.html?hub_id=${hub.hub_id}`; document.location = `/hub.html?hub_id=${hub.hub_id}`;
......
...@@ -99,6 +99,7 @@ const config = { ...@@ -99,6 +99,7 @@ const config = {
useLocalIp: true, useLocalIp: true,
public: "hubs.local:8080", public: "hubs.local:8080",
port: 8080, port: 8080,
headers: { "Access-Control-Allow-Origin": "*" },
before: function(app) { before: function(app) {
// networked-aframe makes HEAD requests to the server for time syncing. Respond with an empty body. // networked-aframe makes HEAD requests to the server for time syncing. Respond with an empty body.
app.head("*", function(req, res, next) { app.head("*", function(req, res, next) {
......
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