allinurl / gwsocket

fast, standalone, language-agnostic WebSocket server RFC6455 compliant
http://gwsocket.io
MIT License
745 stars 67 forks source link

Add option to daemonize process #11

Closed allinurl closed 7 years ago

jirutka commented 7 years ago

Why? This is responsibility of init/rc system, not the program. Adding option to detach and even create a PID file into every program is a bad relict from the age of crappy SysV init. It's just wrong.

allinurl commented 7 years ago

That's a good point and I'm not sure yet if it's worth it since I want to keep gwsocket as simple as possible. Though, the expectation from this is to have an option for those systems (which I believe are still several) that don't rely on systemd daemons.

jirutka commented 7 years ago

This feature is not needed even for SysV init, it'd just simplify the init script. So instead of bloating gwsocket with such functionality, you can provide SysV init script.

BTW I haven't systemd in my mind, basically every init/rc system except plain SysV can daemonize process without boilerplate scripting.

allinurl commented 7 years ago

You are right. I definitely don't want to bloat gwsocket by adding features that can be easily solved or have a straight workaround. If this becomes an issue, I'll look into it again.