cody on Nostr: First of all, I'm glad you chose to run nostr-relay-nestjs! Since you've confirmed ...
First of all, I'm glad you chose to run nostr-relay-nestjs!
Since you've confirmed that the /metrics endpoint is accessible, I believe you've successfully got it up and running, and you're able to access it in some way. Therefore, your relay address would be ws(s)://<ip address or your host name>:<port>
Nostr relay is a WebSocket-based service, so the protocol used is ws(s):// rather than http(s)://
If you're unable to establish a WebSocket connection but can make HTTP requests, I suspect your NGINX configuration might be incorrect. Here's a simple NGINX configuration for a WebSocket service:
```
server {
server_name xxxxx;
location / {
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $host;
proxy_pass
http://127.0.0.1:port;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header X-Real-IP $remote_addr;
}
}
```
If you want to make your relay more easily accessible to others, you can purchase a domain and register DNS through a service like Cloudflare to forward requests to your AWS server.
Published at
2024-09-23 13:53:28Event JSON
{
"id": "47eff07df6e800e89126ad026ac079f537272be1faf9f197cf70c9cc34f76569",
"pubkey": "8125b911ed0e94dbe3008a0be48cfe5cd0c0b05923cfff917ae7e87da8400883",
"created_at": 1727099608,
"kind": 1,
"tags": [
[
"e",
"bea5673819383c7e645900ea890a49a39f38c849a38da659274cb1f4d0dc011a",
"",
"root"
],
[
"e",
"bea5673819383c7e645900ea890a49a39f38c849a38da659274cb1f4d0dc011a",
"",
"reply"
],
[
"p",
"816509826498efe74904f186f4d09e2b987b39113b2d0b285968c288299380fa",
"",
"mention"
]
],
"content": "First of all, I'm glad you chose to run nostr-relay-nestjs!\n\nSince you've confirmed that the /metrics endpoint is accessible, I believe you've successfully got it up and running, and you're able to access it in some way. Therefore, your relay address would be ws(s)://\u003cip address or your host name\u003e:\u003cport\u003e\n\nNostr relay is a WebSocket-based service, so the protocol used is ws(s):// rather than http(s)://\n\nIf you're unable to establish a WebSocket connection but can make HTTP requests, I suspect your NGINX configuration might be incorrect. Here's a simple NGINX configuration for a WebSocket service:\n\n```\nserver {\n server_name xxxxx;\n location / {\n proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;\n proxy_set_header Host $host;\n proxy_pass http://127.0.0.1:port;\n proxy_http_version 1.1;\n proxy_set_header Upgrade $http_upgrade;\n proxy_set_header Connection \"upgrade\";\n proxy_set_header X-Real-IP $remote_addr;\n }\n}\n```\n\nIf you want to make your relay more easily accessible to others, you can purchase a domain and register DNS through a service like Cloudflare to forward requests to your AWS server.",
"sig": "de8a2ae27d9909a6c49f7a7cb8c4ce012e55e4e68da36746a7b255e939218183a705511af240cf4ade0cdd67d40b0ae2358b30f32087f227e809e175a55a8a21"
}