The successful run timestamp exporter didn't work, because the ansible-pull user wouldn't necessarily have the necessary permissions and because the command wouldn't properly work. Move the timestamp export as well as the reboot to separate services, which always run as root, to ensure these operations work and to have a clean setup using systemd services. Also move the successful run timestamp exporter to a custom script to have it work properly.
8 lines
209 B
Desktop File
8 lines
209 B
Desktop File
[Unit]
|
|
Description=ansible-pull successful run timestamp exporter
|
|
After=ansible-pull.service
|
|
Before=ansible-pull-reboot.service
|
|
|
|
[Service]
|
|
Type=oneshot
|
|
ExecStart=ansible-pull-successful-run-timestamp-exporter
|