smartctl exporter role: the default user and group should be root
Just tried out the smartctl exporter role without further configuration and it didn't work. It works after setting smartctl_exporter_system_user and smartctl_exporter_system_group to root.
From https://github.com/prometheus-community/smartctl_exporter/issues/146, the upstream package is intended to be run as root, and the provided SystemD unit files in the upstream package are configured to have root as the user as well. There is some extra steps required in order to allow non-root users to run the exporter.
Therefore, I would suggest changing the defaults to smartctl_exporter_system_user and smartctl_exporter_system_group to root for a better out-of-the-box experience
Good point! I like the systemd unit in the AUR package, perhaps we should base the one in the role on that.
With that being said, we should absolutely try to catch issues like this in the molecule tests.