smarthome icon indicating copy to clipboard operation
smarthome copied to clipboard

add foreground mode to aid systemd service

Open robert-budde opened this issue 9 years ago • 4 comments

In order to use a very sleek systemd service sh.py should not fork while still being not too verbose on logging. Not forking allows systemd to monitor the process without using an additional pid-file.

robert-budde avatar Mar 10 '15 20:03 robert-budde

Marcus, any thoughts on this one?

robert-budde avatar Mar 28 '15 08:03 robert-budde

Maybe -f could be avoided. Example:

  • -d runs sh.py in background, without verbose.
  • -v runs sh.py in foreground, with verbose.
  • -d -v runs sh.py in background, with verbose. Simply specifying nothing should run sh.py in foreground, without verbose mode enabled.

encbladexp avatar Mar 28 '15 12:03 encbladexp

Sure. This would be the most straightforward way of doing things. But it would break compatibility with all existing installations. I assume that this is not going to happen, therfore I proposed a less intrusive way.

robert-budde avatar Mar 28 '15 13:03 robert-budde

Hi,

I will not merge changes to the base system, because I'm going to adapt the license. And if there are other contributors I cannot change it without asking them.

I'm going to send an email to the contributors/developers to discuss this topic.

Regards

Marcus

mknx avatar Mar 29 '15 11:03 mknx