Skip to content

Conversation

@KoenDierckx
Copy link

These changes will solve issue #13
And there is no longer a need to setup a cron job, or systemd timer

@KoenDierckx
Copy link
Author

Also dropped the APT::Periodic::Update-Package-Lists hook
The frequency of updates should not be controlled by a metrics tool

# this is the apt hook provided by the pve exporter. This file shall be placed under /etc/apt/apt.conf.d
APT::Update::Pre-Invoke {"touch /tmp/pkg-exporter-apt-update-pre"; };
APT::Update::Post-Invoke {"touch /tmp/pkg-exporter-apt-update-post"; };
APT::Periodic::Update-Package-Lists "1";
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In my opinion, we should leave that line as commented suggestion in the example

APT::Update::Post-Invoke {"touch /tmp/pkg-exporter-apt-update-post"; };

# These hooks ensure the metrics are automatically updated when apt is run
APT::Update::Post-Invoke-Success {"/usr/local/bin/pkg-exporter"};
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Until we provide a debian package, also those shall be a commented suggestion, as we do not yet have a single way of installation.
In my optionion starting a systemd unit (if present) would be better than calling the binary directly, however that needs some work on the systemd side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants