Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apt repo key handling #1003

Closed
gregharvey opened this issue Mar 24, 2023 · 4 comments
Closed

Apt repo key handling #1003

gregharvey opened this issue Mar 24, 2023 · 4 comments
Assignees
Labels
2.x enhancement New feature or request

Comments

@gregharvey
Copy link
Member

The recent expiry of the Yarn repo key was a bit of a pain, each affected server needed someone to login and run apt-key adv --refresh-keys. While we could add this to a role, it's deprecated in favour of keyring files managed via GPG. We could do with a role to manage this and potentially keep keys fresh. Here's a possibly useful stack exchange post on the matter:

@gregharvey gregharvey added the enhancement New feature or request label Mar 24, 2023
@gregharvey gregharvey added the 2.x label Nov 7, 2023
@gregharvey
Copy link
Member Author

Expanding on this, we have realised that all apt key handling needs to happen at the start, either just after the _init role or as part of it. The issue is if keys have expired then all builds will fail at the first apt-get update run!

So we need a new debian/apt_repositories role that needs to take over handling all apt repos and associated GPG keys, so any repo and key handling needs removing from other roles and handling by the new role. It should accept a list of repos and ensure they are all properly installed before ce-provision continues. It should also force remove and re-install each key so we can be sure it's up to date before it tries to refresh any repo contents.

@gregharvey gregharvey self-assigned this Apr 18, 2024
@gregharvey
Copy link
Member Author

@gregharvey
Copy link
Member Author

That's merged, now working through the roles one by one.

@gregharvey
Copy link
Member Author

This was done, it should now be reasonably safe to assume systemd timers will handle expiring keys.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2.x enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant