1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/duniter_ynh.git synced 2024-09-03 18:26:35 +02:00

[enh] #64: configure Nginx and Duniter to handle WS2P API.

This commit is contained in:
Moul 2018-03-09 08:37:46 +01:00
parent 5f211909b3
commit b32855f1a4
2 changed files with 7 additions and 0 deletions

View file

@ -43,4 +43,10 @@ location / {
access_by_lua_file /usr/share/ssowat/access.lua; access_by_lua_file /usr/share/ssowat/access.lua;
} }
location /ws2p {
proxy_pass http://127.0.0.1:20901;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
} }

View file

@ -49,6 +49,7 @@ INSTALL_DUNITER_DEBIAN_PACKAGE
# Configure Duniter node # Configure Duniter node
sudo duniter config --ipv4 127.0.0.1 --port $port --remoteh $domain --remotep 80 --noupnp sudo duniter config --ipv4 127.0.0.1 --port $port --remoteh $domain --remotep 80 --noupnp
sudo duniter config --addep "BMAS $domain 443" sudo duniter config --addep "BMAS $domain 443"
sudo duniter config --ws2p-host 127.0.0.1 --ws2p-port 20901 --ws2p-remote-host $domain --ws2p-remote-port 443 --ws2p-noupnp
# Reset Duniter node's existing data (blockchain, not conf) # Reset Duniter node's existing data (blockchain, not conf)
sudo duniter reset data > /dev/null sudo duniter reset data > /dev/null