6 ms·
How would you solve a task like creating an user group or things that are more complicated then dropping some files on the disk?
by simion314 8y ago
How would you solve a task like creating an user group or things that are more complicated then dropping some files on the disk?
- heinrichhartman 8y agoAdding new systemd service, for example just requires me to put a file into `/etc/systemd/system`. Many other applications work like this as well: Apache configs, /etc/sudoers.d on Debian, more examples in `/etc/?.d` It's generally a good practice to make your system open for extension but closed to modifications [1]. There is no reason, the user database can not work the same way. Just have the system scan `/etc/passwd.d/*` on boot/reload and drop files there. [1] https://drive.google.com/file/d/0BwhCYaYDn8EgODUxZTJhOWEtMTZlMi00OWRiLTg0ZmEtZWQ5ODRlY2RmNDlk/view https://drive.google.com/file/d/0BwhCYaYDn8EgODUxZTJhOWEtMTZ...
- toast0 8y agoUser management could be handled as part of the package metadata, rather than an install script. Schema migrations would still need a script or something though.