Skip to content

Commit

Permalink
chore(ephemeral): add debug log when bringing up ephemeral network (#…
Browse files Browse the repository at this point in the history
…5010)

A debug message is logged whenever an instance is able to connect 
to the IMDS but when it can't, and an ephemeral network needs 
brought up, nothing is logged. Adding a log message here will help 
improve readability of logs and help troubleshoot failure paths 
when an instance is having issues with networking.
  • Loading branch information
a-dubs authored Mar 6, 2024
1 parent 5b80ba1 commit d86f35a
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion cloudinit/net/ephemeral.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,12 @@ def __enter__(self):
self.connectivity_url_data["url"],
)
return

else:
LOG.debug(
"Instance does not have connectivity to %s. Bringing up "
"ephemeral network now.",
self.connectivity_url_data["url"],
)
try:
self._bringup_device()

Expand Down

0 comments on commit d86f35a

Please sign in to comment.