headscale icon indicating copy to clipboard operation
headscale copied to clipboard

Add reload and test config commands

Open 0xcd0e opened this issue 3 years ago • 6 comments

Like the nginx -t command, it would be nice to verify the config (config.json, derp map, acl) prior to loading it. Also, like nginx -s reload, it would be nice to reload the configuration during runtime without having to restart the service.

0xcd0e avatar Oct 16 '21 16:10 0xcd0e

I see the point of this, but I reckon we should develop first an internal API to communicate the CLI with the running service.

Also, bear in mind that given how Tailscale works, restarting the service does not break the connectivity of the nodes.

juanfont avatar Oct 17 '21 11:10 juanfont

Yeah I am aware that this is more of an advanced feature and probably premature in the current state of the project :)

0xcd0e avatar Oct 17 '21 11:10 0xcd0e

You mean the current AMAZING state of the project 🤣

juanfont avatar Oct 17 '21 11:10 juanfont

Oh no dont get me wrong, I think this project is amazing! I meant the early state of it, not that it was in any way bad :D

0xcd0e avatar Oct 17 '21 11:10 0xcd0e

We should handle signals, so we can do what "traditional" unix apps does and reload the configfile, acls etc on HUP and do graceful shutdown on INT, KILL, etc.

kradalby avatar Mar 20 '22 14:03 kradalby

Adding this support for ACLs in #601, in addition to a bit more graceful signal handling for shutdown.

Config reload will have to sit for a bit more, I think we need to do a few rounds of cleanups in the config handling first, to decouple it so this is possible.

kradalby avatar May 31 '22 12:05 kradalby

This issue is stale because it has been open for 180 days with no activity.

github-actions[bot] avatar Oct 13 '23 01:10 github-actions[bot]

This issue was closed because it has been inactive for 14 days since being marked as stale.

github-actions[bot] avatar Oct 28 '23 01:10 github-actions[bot]