Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

atdixon/me.untethr.nostr-relay

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

70 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

me.untethr.nostr-relay

A nostr relay, written in Clojure, backed by sqlite3.

Supported NIPs: NIP-01, NIP-02, NIP-04, NIP-11, NIP-12, NIP-15, NIP-16, NIP-20, NIP-22, NIP-42

(NIP-09, NIP-26, NIP-33, NIP-40, NIP-50 not yet supported, but please request with your client & use case if you're interested.)

Project Goals

  • solid nips coverage & data completeness + accuracy
  • speed and performance on modest hardware

Run Locally

For a real deployment, you'll want to deploy with ssl termination (e.g. using ngnix) but for local testing, simply:

$ brew install clojure/tools/clojure
$ make run

The relay will be reachable at ws://localhost:9090 and data in a git-ignored ./n.db sqlite file

With various app metrics available at http://localhost:9090/metrics.

Edit ./conf/relay.yaml to change port, file, etc.

Known Deployments

  • wss://nostr-relay.untethr.me
  • wss://relay.kronkltd.net

How to Deploy

Use a latest release from releases.

A released tar.gz archive has these contents:

me.untethr.nostr-relay.jar
conf/relay.yaml
conf/nip05.json
conf/nip11.json
conf/logback.xml

Unpack on server, update config files to your personal liking (note: leave the "supported_nips" and "version" as-is in the nip11.json file), and run (using java 11+):

$ java -Xms1g -Xmx1g \
    -Dlogback.configurationFile=conf/logback.xml \
    -cp me.untethr.nostr-relay.jar \
    clojure.main -m me.untethr.nostr.app

This runs the relay on the port specified in conf/relay.yaml (default 9090).

You'll want your users to hit a reverse proxy, configured to serve SSL traffic (wss://...) and proxy to the relay server.

See Deploy for more information on how to run a real deployment.

Develop

The best place to start reading the code is from the -main method in the well-documented me.untethr.nostr.app namespace.

If you're developing you can build a jar or deployment archive from latest source, like so:

$ make uberjar

or

$ make deploy-archive

About

A fast nostr relay, written in Clojure.

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.