digitalocean / do-agent

Collects system metrics from DigitalOcean Droplets
Apache License 2.0
597 stars 99 forks source link

Stop using apt-key (fixes Ubuntu 22 warnings) #290

Closed notpeter closed 1 year ago

notpeter commented 1 year ago

Under Ubuntu22 and debian bullseye (stable) warnings are issued every time apt-get update is run:

W: https://repos.insights.digitalocean.com/apt/do-agent/dists/main/InRelease: Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details.

This PR alters the do-agent install.sh script to follow the pattern used in the droplet-agent install script to not use apt-key because apt-key and /etc/apt/trusted.gpg are deprecated in Ubuntu22 and Debian bullseye.

Related DO Community Question (2022-06-19)

Fixes #268 (2022-06-20) Fixes #273 (2022-11-09)

P.S. y'all might want to include something in the readme here and in https://github.com/digitalocean/droplet-agent/ to explicitly disambiguate and cross-link between the two repos. It's be totally understandable for folks to confuse do-agent with droplet-agent (see @hobhobuk's answer in above linked DO Community Question for an example of that happening).

P.P.S. Similarly I think it'd be totally appropriate to add a line to the top each install.sh script NAMING the product that's about to be installed and explicitly link to the associated GitHub repo.

prichrd commented 1 year ago

Hey @notpeter,

Thank you for the contribution and the feedback; it is much appreciated. Our team will only be partially present during the upcoming weeks, but this is our priority to fix when we come back in the new year. We will roll out your fix, plus other small things that need to go along with it.

prichrd commented 1 year ago

Everything is rolled-out and deployed. Thank you for your contribution @notpeter !