Add support for server lifetime
Terminates client/server after some period of time, regardless of active connections. Designed for security at work. Default should be 8 hours.
Used to have this as --shutdown-after. The annoying thing was that this was done by checking if we had no active connections to the server. Instead, we probably want multiple options:
- Never expire
- Expire after X amount of time regardless of connections
- Expire after X amount of time with no connections
Could rename --shutdown-after to --shutdown and provide an enum that parses a string.
--shutdown neverwill yieldShutdown::Never--shutdown [lonely=]<number>will yieldShutdown::Lonely(Duration)(compatible with old--shutdown-after <number>--shutdown always=<number>will yieldShutdown::Always(Duration)that will shut the server down after N seconds regardless
Resolved by https://github.com/chipsenkbeil/distant/commit/74a37209eb2e973200011ed19d86ee8840cea1f4.
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.