Skip to content

Commit 16f61d5

Browse files
authored
Update example blockdaemon nginx pythnet config (#278)
1 parent 56d422d commit 16f61d5

File tree

1 file changed

+29
-11
lines changed

1 file changed

+29
-11
lines changed

doc/example-nginx-blockdaemon.conf

Lines changed: 29 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -14,31 +14,49 @@ http {
1414

1515
client_max_body_size 0;
1616

17-
upstream bdnodes {
18-
server YOUR_NODE.bdnodes.net:443;
19-
server YOUR_NODE.bdnodes.net:443;
20-
server YOUR_NODE.bdnodes.net:443;
21-
keepalive 4;
17+
# Pythnet servers
18+
server {
19+
listen 7900;
20+
server_name pythnet.localhost;
21+
location / {
22+
proxy_set_header Upgrade $http_upgrade;
23+
proxy_set_header Connection "Upgrade";
24+
proxy_ssl_server_name on;
25+
proxy_set_header Host "rpc.mainnet.pythnet.blockdaemon.tech";
26+
proxy_pass https://rpc.mainnet.pythnet.blockdaemon.tech:443/websocket;
27+
}
28+
}
29+
server {
30+
listen 7899;
31+
server_name pythnet.localhost;
32+
location / {
33+
proxy_http_version 1.1;
34+
proxy_set_header Connection "";
35+
proxy_ssl_server_name on;
36+
proxy_set_header Host "rpc.mainnet.pythnet.blockdaemon.tech";
37+
proxy_pass https://rpc.mainnet.pythnet.blockdaemon.tech:443/;
38+
}
2239
}
2340

41+
# Solana servers
2442
server {
2543
listen 7900;
44+
server_name solana.localhost;
2645
location / {
27-
proxy_http_version 1.1;
2846
proxy_set_header Upgrade $http_upgrade;
2947
proxy_set_header Connection "Upgrade";
30-
proxy_set_header Authorization "Bearer YOUR_AUTH_TOKEN_HERE";
31-
proxy_pass https://bdnodes/websocket;
48+
proxy_set_header Authorization "Bearer <token>";
49+
proxy_pass https://YOUR_NODE.bdnodes.net:443/websocket;
3250
}
3351
}
34-
3552
server {
3653
listen 7899;
54+
server_name solana.localhost;
3755
location / {
3856
proxy_http_version 1.1;
3957
proxy_set_header Connection "";
40-
proxy_set_header Authorization "Bearer YOUR_AUTH_TOKEN_HERE";
41-
proxy_pass https://bdnodes/;
58+
proxy_set_header Authorization "Bearer <token>";
59+
proxy_pass https://YOUR_NODE.bdnodes.net:443/;
4260
}
4361
}
4462
}

0 commit comments

Comments
 (0)