Module ::filesystem
Read only access to the host file system and the configuration directory
Host file system access
Be careful with host file system access, since it can make your configuration non-deterministic.
The main purpose of this is for things that shouldn't be stored in your git managed configuration, in particular for passwords and other secrets:
- Hashed passwords from
/etc/shadow
- Passwords for wireless networks
- Passwords for any services needed (such as databases)
Another use case is to read some system information from /sys
that isn't already exposed by other APIs
Configuration directory access
This is generally safe, in order to read files that are part of the configuration (if you want to use them as templates for example and fill in some values)
Use File::open_from_config
for this. In special circumstances (together with the process
module) you may also need config_path
.
Temporary directories
This is generally not needed when working with konfigkoll, but can be useful for interacting with external commands via the process
module.