landscape-client: handle already registered client
landscape-client: handle already registered client
This PR makes use of "is-registered" parameter to prevent duplicate entries
of clients on a Landscape server when cloud-init runs more than once.
Additional Context
The parameter was introduced to landscape-client in version 23.02 (https://github.com/canonical/landscape-client/pull/103) and has been available in "release (main)" repository since Lunar. The package is currently in "proposed" repository for Focal as well as Jammy and will hopefully be released in near future. So please keep in mind, if this PR should make it's way in the upstream we have to take care about the current release status of all supported Ubuntu releases. Please have a look at launchpad
Test Steps
Checklist
- [x] My code follows the process laid out in the documentation
- [x] I have updated or added any unit tests accordingly
- [x] I have updated or added any documentation accordingly
Merge type
- [x] Squash merge using "Proposed Commit Message"
- [ ] Rebase and merge unique commits. Requires commit messages per-commit each referencing the pull request number (#<PR_NUM>)
Implemented changes you requested. Furthermore, I added some unit tests. Please review again. thx
Still waiting on SRU resolution for landscape-client before this lands.
Hello! Thank you for this proposed change to cloud-init. This pull request is now marked as stale as it has not seen any activity in 14 days. If no activity occurs within the next 7 days, this pull request will automatically close.
If you are waiting for code review and you are seeing this message, apologies! Please reply, tagging TheRealFalcon, and he will ensure that someone takes a look soon.
(If the pull request is closed and you would like to continue working on it, please do tag TheRealFalcon to reopen it.)
@blackboxsw , looks like the last comment on that bug is from 2023-10-20 . Do we expect that to be SRUed anytime soon?
@blackboxsw , looks like the last comment on that bug is from 2023-10-20 . Do we expect that to be SRUed anytime soon?
Yep. I had circled back with the team and was assured they had it on their planning and it looks like verification just got unblocked yesterday. We expect this release within a week now that verification is complete for Focal/Jammy. https://bugs.launchpad.net/landscape-client/+bug/2006402/comments/53
Checked again on this landscape-client SRU. All tests are verified, SRU review queue is saturated given demand for Noble release reviews. Giving this another week to allow the Noble release week testing to pass this week which should free up SRU vanguards to unblock landscape-client publication.
chifac08 looks like landscape-client published yesterday. I just validated your PR works great on both Ubuntu focal and jammy with the newly published landscape-client --is-registered param. Finally landing this without further delay.