Fix authentication on preview builds

We want to be able to authenticate on any host. Previously we'd assume
that production builds only authenticate with app.radicle.xyz.
This commit is contained in:
Rūdolfs Ošiņš
2023-11-30 11:07:14 +01:00
parent 3724e08a6a
commit 32acc74a76
+3 -5
View File
@@ -12,11 +12,9 @@
import TextInput from "@app/components/TextInput.svelte";
$: customUrl = `${httpd.api.baseUrl.scheme}://${httpd.api.baseUrl.hostname}:${customPort}`;
$: command = import.meta.env.PROD
? `rad web --backend ${customUrl}`
: `rad web --frontend ${
new URL(import.meta.url).origin
} --backend ${customUrl}`;
$: command = `rad web --frontend ${
new URL(import.meta.url).origin
} --backend ${customUrl}`;
let customPort = httpd.api.port;
$: validPortNumber = Number(customPort) > 0 && Number(customPort) <= 65535;