Closed petterreinholdtsen closed 10 years ago
Probably the path should be more general, eg, /var/lib/serval/localnode
. That way, if we ever came to a situation where a node ran more than one Serval daemon (which is possible but not needed by any deployment yet) then we could create several sub directories under /var/lib/serval
, one for each instance.
For proper FHS compliance, the contents of the Serval instance directory really should be split between several directories:
/etc/serval/servald.conf
/etc/serval/serval.keyring
/var/run/servald.pid
/var/log/serval/
/var/lib/serval/
or perhaps /var/cache/serval
This could be implemented as the standard behaviour if the SERVALINSTANCE_PATH
env var is not set. To allow for multiple daemons on the same host, a new env var SERVALD_CONFIG
could be supported which pointed to a single config file, which in turn would configure the other paths.
If the SERVALINSTANCE_PATH
env var is set, all paths would be formed as they currently are, to preserve compatibility. This env var might be deprecated and removed in future.
Some work has been done in ba44088e & 53c1b1c0. Can we close this now?
FHS paths are now fully supported and configurable, but not the SERVALD_CONFIG
env var discussed above. See the FHS Paths section of Servald-Configuration.md for the details.
According to the file hiearcy standard, used by Debian and others to decide where in the file system a file belong, packages should store their stuff in /var/lib/foo, not /var/foo. Because of this, I suggest to move /var/serval-node to /var/lib/serval-node.