mirror of
https://github.com/RoboSats/robosats.git
synced 2025-07-19 01:03:20 +00:00
freedomsats Node app
This commit is contained in:
70
nodeapp/coordinators/freedomsats/locations.conf
Normal file
70
nodeapp/coordinators/freedomsats/locations.conf
Normal file
@ -0,0 +1,70 @@
|
||||
# Libre freedomsats Mainnet Locations
|
||||
location /mainnet/freedomsats/static/assets/avatars/ {
|
||||
proxy_pass http://mainnet_freedomsats/static/assets/avatars/;
|
||||
}
|
||||
|
||||
location /mainnet/freedomsats/api/ {
|
||||
# if ($request_method = 'OPTIONS') {
|
||||
# add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS';
|
||||
# add_header 'Access-Control-Allow-Headers' 'DNT,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range';
|
||||
# add_header 'Access-Control-Max-Age' 1728000;
|
||||
# add_header 'Content-Type' 'text/plain; charset=utf-8';
|
||||
# add_header 'Content-Length' 0;
|
||||
# return 204;
|
||||
# }
|
||||
# if ($request_method = 'POST') {
|
||||
# add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS';
|
||||
# add_header 'Access-Control-Allow-Headers' 'DNT,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range';
|
||||
# add_header 'Access-Control-Expose-Headers' 'Content-Length,Content-Range';
|
||||
# }
|
||||
# if ($request_method = 'GET') {
|
||||
# add_header 'Access-Control-Allow-Methods' 'GET, POST, OPTIONS';
|
||||
# add_header 'Access-Control-Allow-Headers' 'DNT,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range';
|
||||
# add_header 'Access-Control-Expose-Headers' 'Content-Length,Content-Range';
|
||||
# }
|
||||
proxy_pass http://mainnet_freedomsats/api/;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "Upgrade";
|
||||
proxy_set_header Host $host;
|
||||
}
|
||||
|
||||
location /mainnet/freedomsats/ws/ {
|
||||
proxy_pass http://mainnet_freedomsats/ws/;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "Upgrade";
|
||||
proxy_set_header Host $host;
|
||||
}
|
||||
|
||||
location /mainnet/freedomsats/relay/ {
|
||||
proxy_pass http://mainnet_freedomsats/relay/;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "Upgrade";
|
||||
proxy_set_header Origin $http_origin;
|
||||
proxy_set_header Host $host;
|
||||
|
||||
add_header Access-Control-Allow-Origin *;
|
||||
}
|
||||
|
||||
# BitcoinVeneto Coordinator Testnet Locations
|
||||
location /test/freedomsats/static/assets/avatars/ {
|
||||
proxy_pass http://testnet_freedomsats/static/assets/avatars/;
|
||||
}
|
||||
|
||||
location /testnet/freedomsats/api/ {
|
||||
proxy_pass http://testnet_freedomsats/api/;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "Upgrade";
|
||||
proxy_set_header Host $host;
|
||||
}
|
||||
|
||||
location /testnet/freedomsats/ws/ {
|
||||
proxy_pass http://testnet_freedomsats/ws/;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "Upgrade";
|
||||
proxy_set_header Host $host;
|
||||
}
|
9
nodeapp/coordinators/freedomsats/upstreams.conf
Normal file
9
nodeapp/coordinators/freedomsats/upstreams.conf
Normal file
@ -0,0 +1,9 @@
|
||||
# Libre freedomsats Coordinator Mainnet
|
||||
upstream mainnet_freedomsats {
|
||||
server localhost:108;
|
||||
}
|
||||
|
||||
# Libre freedomsats Coordinator Testnet
|
||||
upstream testnet_freedomsats {
|
||||
server localhost:1008;
|
||||
}
|
@ -38,6 +38,8 @@ http {
|
||||
include /etc/nginx/conf.d/moon/upstreams.conf;
|
||||
# Libre Bazaar
|
||||
include /etc/nginx/conf.d/bazaar/upstreams.conf;
|
||||
# FreedomSats
|
||||
include /etc/nginx/conf.d/freedomsats/upstreams.conf;
|
||||
|
||||
server {
|
||||
|
||||
@ -80,6 +82,8 @@ http {
|
||||
include /etc/nginx/conf.d/moon/locations.conf;
|
||||
# Libre Bazaar
|
||||
include /etc/nginx/conf.d/bazaar/locations.conf;
|
||||
# FreedomSats
|
||||
include /etc/nginx/conf.d/freedomsats/locations.conf;
|
||||
|
||||
# do not log healtchecks made against "/selfhosted"
|
||||
location /selfhosted {
|
||||
|
@ -69,5 +69,18 @@ mainnet_bazaar_socat="socat tcp4-LISTEN:${mainnet_bazaar_port},reuseaddr,fork,ke
|
||||
testnet_bazaar_socat="socat tcp4-LISTEN:${testnet_bazaar_port},reuseaddr,fork,keepalive,bind=127.0.0.1 SOCKS4A:${TOR_PROXY_IP:-127.0.0.1}:${testnet_bazaar_onion}:80,socksport=${TOR_PROXY_PORT:-9050}"
|
||||
|
||||
|
||||
################################
|
||||
# Freedomsats
|
||||
# Mainnet
|
||||
mainnet_freedomsats_onion=dqmmejfmtlve7d4ccohk4usriifdtci6xk4wv7igxn2fyaduh25s6did.onion
|
||||
mainnet_freedomsats_port=108
|
||||
# Testnet
|
||||
testnet_freedomsats_onion=dqmmejfmtlve7d4ccohk4usriifdtci6xk4wv7igxn2fyaduh25s6did.onion
|
||||
testnet_freedomsats_port=1008
|
||||
# socat cmd
|
||||
mainnet_freedomsats_socat="socat tcp4-LISTEN:${mainnet_freedomsats_port},reuseaddr,fork,keepalive,bind=127.0.0.1 SOCKS4A:${TOR_PROXY_IP:-127.0.0.1}:${mainnet_freedomsats_onion}:80,socksport=${TOR_PROXY_PORT:-9050}"
|
||||
testnet_freedomsats_socat="socat tcp4-LISTEN:${testnet_freedomsats_port},reuseaddr,fork,keepalive,bind=127.0.0.1 SOCKS4A:${TOR_PROXY_IP:-127.0.0.1}:${testnet_freedomsats_onion}:80,socksport=${TOR_PROXY_PORT:-9050}"
|
||||
|
||||
|
||||
# RUN!
|
||||
$mainnet_temple_socat & $testnet_temple_socat & $mainnet_lake_socat & $testnet_lake_socat & $mainnet_veneto_socat & $testnet_veneto_socat & $mainnet_moon_socat & $testnet_moon_socat & $mainnet_bazaar_socat & $testnet_bazaar_socat & nginx
|
||||
$mainnet_temple_socat & $testnet_temple_socat & $mainnet_lake_socat & $testnet_lake_socat & $mainnet_veneto_socat & $testnet_veneto_socat & $mainnet_moon_socat & $testnet_moon_socat & $mainnet_bazaar_socat & $testnet_bazaar_socat & $mainnet_freedomsats_socat & $testnet_freedomsats_socat & nginx
|
||||
|
Reference in New Issue
Block a user