canonical / canonical/pycloudlib
ip() calls should get cached
Open
- Dominant language
- Python
- Stars
- 22
- Forks
- 42
- PR merge metrics
- No merged PRs in 30d
Description
Every Instance has an ip() method. In cloud-init, when tearing down, we have the option of keeping instance so that it can be further debugged. To make this easy, we print the IP of the instance being torn down. However, this can cause issues on "clouds" like LXD that dynamically fetch the IP. In my case, I took a snapshot of the instance first, so the instance was shutdown (but not removed). The call to get the IP then retries 150 times, eventually failing.
It's fine (not ideal) if the call fails, but waiting 150 tries is a bit much.
Contributor guide
Assessment
This issue has not been assessed yet.