allow publishing events from allowed pubkeys without auth, if env variable is set
This commit is contained in:
parent
3367cb929b
commit
22a4fe069f
2 changed files with 13 additions and 5 deletions
3
index.ts
3
index.ts
|
@ -1,7 +1,8 @@
|
|||
import { main } from "./src/main.ts";
|
||||
|
||||
let allowUnauthedPublish = Boolean(process.env.ALLOW_UNAUTHED_PUBLISH) || false;
|
||||
let relay = process.env.RELAY_URL ?? Bun.argv[Bun.argv.length - 1];
|
||||
if (!relay?.startsWith("wss://") && !relay?.startsWith("ws://"))
|
||||
relay = "wss://relay.arx-ccn.com";
|
||||
|
||||
main(relay)
|
||||
main(relay, allowUnauthedPublish)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue