I have an ipfs node that is behind a corporate firewall and can only talk to the outside world via an http proxy.
- In principle, the websocket transport should be able to work through a HTTP proxy. Is that possible?
- Does the websocket transport use the encryption of private swarms, or will it be unencrypted?
- How does go-ipfs pick up the proxy settings? Will the usual environment variables (http_proxy etc) be picked up?
I did a few experiments, letting a public node listen on 8081/ws, but was unable to connect to that node.
ipfs swarm connect /ip4/54.145.7.219/tcp/8081/ws/ipfs/QmRSGx67Kq8w7xSBDia7hQfbfuvauMQGgxcwSWw976x4BS
Error: connect QmRSGx67Kq8w7xSBDia7hQfbfuvauMQGgxcwSWw976x4BS failure: dial attempt failed: <peer.ID ZABeAH> --> <peer.ID RSGx67> dial attempt failed: no dialer for /ip4/54.145.7.219/tcp/8081/ws
Even though the node is clearly listening on the port. Am I missing something obvious?
Edit: I configured public node to listeo on websocket like this:
"Addresses": {
"Swarm": [
"/ip4/0.0.0.0/tcp/4001",
"/ip4/0.0.0.0/tcp/8081/ws",
"/ip6/::/tcp/4001"
],
Edit 2: connecting to the endpoint using wscat does produce something that looks very much like ipfs, so at least the node seems to be properly configured.
wscat -c http://54.145.7.219:8081/
connected (press CTRL+C to quit)
< /multistream/1.0.0