Skip to content

Commit

Permalink
core: frontend: warn developers if they use a bad BLUEOS_ADDRESS envi…
Browse files Browse the repository at this point in the history
…ronment variable
  • Loading branch information
Williangalvani committed Jan 17, 2024
1 parent 8b6709b commit 34dd085
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions core/frontend/vite.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ const DEFAULT_ADDRESS = 'http://blueos-avahi.local/'
const SERVER_ADDRESS = process.env.BLUEOS_ADDRESS ?? DEFAULT_ADDRESS

const path = require('path')
const assert = require('assert');

// TODO: check if it works with https once we have something that does
assert.ok(SERVER_ADDRESS.startsWith('http://'), 'SERVER_ADDRESS must start with http://');

export default defineConfig({
plugins: [
Expand Down

0 comments on commit 34dd085

Please sign in to comment.