diff --git a/README.md b/README.md index a3e7026c4e4d15a72fbdef4629ddc756f579f112..ff0f722921d6ece639d1828af70d2ea27e18257d 100644 --- a/README.md +++ b/README.md @@ -21,6 +21,12 @@ To bundle javascript and generate the html templates, run: yarn build ``` +## hubs.local Host Entry + +When running the full stack for Hubs (which includes [Reticulum](https://github.com/mozilla/reticulum)) +locally it is necessary to add a `hosts` entry pointing `hubs.local` to your local server's IP. +This will allow the CSP checks to pass that are served up by Reticulum so you can test the whole app. + ## Query Params - `room` - Id of the room (an integer) that you want to join diff --git a/scripts/build_local_reticulum.sh b/scripts/build_local_reticulum.sh index 3f5e3a00136a84adf99b68926ee0dd1b17a09af3..9a19f9f202b688b27213b0478f9e1a14e67d2620 100755 --- a/scripts/build_local_reticulum.sh +++ b/scripts/build_local_reticulum.sh @@ -4,4 +4,4 @@ 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://localhost:4000/ yarn build -- --output-path ../reticulum/priv/static +rm -rf ../reticulum/priv/static ; GENERATE_SMOKE_TESTS=true BASE_ASSETS_PATH=https://hubs.local:4000/ yarn build -- --output-path ../reticulum/priv/static diff --git a/webpack.config.js b/webpack.config.js index 17fbb4f8b666a03a7d1577f07d011040b6125f40..6f66a85c9c59fb1cbd5a339519af6eec23987eb7 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -41,6 +41,10 @@ function createHTTPSConfig() { { type: 2, value: "localhost" + }, + { + type: 2, + value: "hubs.local" } ] } @@ -93,6 +97,7 @@ const config = { https: createHTTPSConfig(), host: "0.0.0.0", useLocalIp: true, + public: "hubs.local:8080", port: 8080, before: function(app) { // networked-aframe makes HEAD requests to the server for time syncing. Respond with an empty body.