On Thu, Nov 02, 2017 at 09:24:51PM +0100, Thomas Liske wrote:
> Marc Haber <[email protected]> writes:
> > during automated processes, such as puppet runs or automated upgrades,
> > it is sometimes acceptable to restart daemons without asking. In this
> > case, I would like to have my system return to the normal way of
> > operation after the automated processing. It would, therefore, be not a
> > good idea to actually modify /etc/apt/apt.conf.d/99needrestart because
> > one would need to re-edit the file to its original state.
> >
> > Would it be possible to have /usr/lib/needrestart/apt-pinvoke source a
> > (normally not existing) /etc/needrestart.conf where one could put the
> > options in? or even an /etc/needrestart.d where one could drop a file
> > and remove it afterwards?
>
> you could extend needrestart's configuration by putting a file into
> /etc/needrestart/conf.d/. Since the config files are sourced perl
> scripts it would be even possible to test for env variables or existing
> of files and change the configuration dynamicly. Does this already solve
> your request?
That looks good, but I think the last part is missing.
> There is already support for an environment variable
> ("NEEDRESTART_SUSPED") to temporary deactivate needrestart. Do you think
> there should be support for another variable like "NEEDRESTART_MODE" to
> be able to override the configured mode?
I didn't find any possibility in needrestart.conf to set the equivalent
of the -r option. Maybe that's a documentation issue?
If I can set the equivalent of -r a from a /etc/needrestart/conf.d/
snippet, I'm fine and this reprt can be closed.
Greetings
Marc
--
-----------------------------------------------------------------------------
Marc Haber | "I don't trust Computers. They | Mailadresse im Header
Leimen, Germany | lose things." Winona Ryder | Fon: *49 6224 1600402
Nordisch by Nature | How to make an American Quilt | Fax: *49 6224 1600421