[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Per-user package configuration



Dmitry Bogatov writes:
> I am working on runit process supervision suite, and I want to provide
> user-local supervision support out-of-binary-package. User-local supervision for
> requires one file pre user in /etc.  (Well, true is a
> bit more complex, but nevermind). One extra will be spawned per user).
>
> Question is: how to properly configure all this?

I would just let the administrator configure this, without debconf.

You might also look at what systemd does: start the supervisor for users
on login (and stop on logout), and allow users to request the supervisor
to be started at boot (and kept after logout) and give administrators
options to allow/deny such requests.

> My best idea so far is provide at installation time list of users with
> uid >= 1000, and ask for which of them user-local supervision should
> be enabled. But seems that debconf templates are static, and I can't
> dynamically generate list of choices (users). But I need to, since
> users can be added and removed, and I want 'dpkg-reconfigure' handle
> it.

That seems unhelpful on any installation that doesn't just have up to
five local users, but use an LDAP directory with thousands of users.

> Another, more crude, alternative is just enable user-local supervision
> for every user availiable in postinst. But it is not so nice to
> require sysadmin to run 'dpkg-reconfigure' every time user is removed
> or added.

This is probably also a bad idea if many users exist.

Ansgar


Reply to: