Closed vyzo closed 7 years ago
Big 👍 on the refactor; the code is much easier to follow now :)
For setting the status, can we make that a POST instead of GET /status/public
? I feel like state changes via GET is a REST no-no 😄
Per our discussion: POST is the canonical method for setting the state in /status/{state}
but the implementation also happens to accept GET as well :)
Eventually we can add some proper method discremination (the gorilla mux certainly supports it), but I don't want to complicate yet.
Cool, then I say 👍 to this PR. I'll add the new commands to the aleph REST client in a little bit
client support merged in aleph; merging.
Heavily refactors mcnode by splitting into multiple files and implements offline node behavior.
The node now starts offline by default, and it can transition to online (listening to the network) or public (online + registered with the directory) through the
/status
REST API. Before a node can transition to public, a directory must be configured through the/config/dir
REST API.Here is an example: