vault713 / wallet713

A wallet that makes it easy to send, store, and swap Grin.
Apache License 2.0
196 stars 74 forks source link

Enable 443 to be used for multiple listeners? #116

Closed lehnberg closed 5 years ago

lehnberg commented 5 years ago

As an anonymous cryptocurrency creator looking to accept donations from users via both https and grinbox, I'd like to be able to run both my https and grinbox listener concurrently, so that I don't have to run two separate servers.

Not even sure this is possible, but relevant Gitter chat log:

Ignotus Peverell @ignopeverell Feb 03 23:55 might have to use a different server, the listener is already taking 443 on that one

ignopeverell commented 5 years ago

Not possible to run 2 servers on the same port. But given that you guys already embed a lot of grin wallet code, you could run the listener as part of wallet713 and sniff if the message coming in is for the grin listener or your own protocol and forward/process accordingly.

lehnberg commented 5 years ago

Okay so @ignopeverell after some discussion with @ravidio, no additional work is required for this, wallet713 supports running an https and grinbox listener from the same machine as is.

Steps:

  1. Run wallet713 only.
  2. Enable Foreign API by editing ~/.wallet713/main/wallet713.toml and including
    foreign_api=true
    foreign_api_address = "0.0.0.0:13415"

    where you specify IP:PORT bind.

  3. Configure your domain and https certs correctly.
  4. Run wallet713, and that's it. You should now be listening on the IP assigned to you on the network. And if you set up DNS etc it can be accessible via a domain name.
  5. To run grinbox listener, you either run listen inside the wallet or configure wallet713.toml to include grinbox_listener_auto_start = true in order for it to start automatically.
lehnberg commented 5 years ago

Also, just to clarify: The grinbox listener does not need an inbound port.