cloudinit: tweak logs on combined json error cases
This commit is contained in:
parent
ec2574009a
commit
2907f87411
|
@ -15,6 +15,12 @@ def get_host_combined_cloud_config() -> dict:
|
|||
"Loaded cloud config from /run/cloud-init/combined-cloud-config.json"
|
||||
)
|
||||
return config
|
||||
except (IOError, OSError, AttributeError, json.decoder.JSONDecodeError):
|
||||
log.debug("Failed to load combined-cloud-config")
|
||||
except FileNotFoundError:
|
||||
log.debug(
|
||||
"Failed to load combined-cloud-config, file not found. "
|
||||
"This is expected for cloud-init <= v23.2.1."
|
||||
)
|
||||
return {}
|
||||
except (IOError, OSError, AttributeError, json.decoder.JSONDecodeError) as ex:
|
||||
log.debug("Failed to load combined-cloud-config: %s", ex)
|
||||
return {}
|
||||
|
|
Loading…
Reference in New Issue