You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We sometimes move nodes between different clouds and end up with situations where the cloud helper functions return erroneous results. For example, when a node was moved from Azure to AWS, ohai reports azure is present, but azure.metadata is null
Also note cloud key is missing for the attributes in the example. And to be clear the node can be seen still running in the EC2 console, all the AWS attributes are valid.
Result of helpers for above node:
chef (17.10.3)> ec2?
=> true
chef (17.10.3)> azure?
=> true
chef (17.10.3)> cloud?
=> false
We expected true, false and true in this case. The node is still running in ECS. Also we don't understand how cloud? can ever be false if one of the cloud provider helpers is true.
Sometimes the cloud metadata is missing too, even though the node is running in EC2 or similar. We think this may have to do with moving a node from on-prem to the cloud.
Checking the helper methods, it looks like they only check for the presence of the azure key and such. Maybe more robust checking is needed for edge cases like these.
Chef Version
17.10.3
Platform Version
WSL Ubuntu 22.04.03 LTS
Replication Case
Transfer node from Azure to AWS, or on-prem to Azure to AWS
Observe metadata that retains/misses azure or cloud attributes
The text was updated successfully, but these errors were encountered:
Description
We sometimes move nodes between different clouds and end up with situations where the cloud helper functions return erroneous results. For example, when a node was moved from Azure to AWS,
ohai
reportsazure
is present, butazure.metadata
is nullAlso note
cloud
key is missing for the attributes in the example. And to be clear the node can be seen still running in the EC2 console, all the AWS attributes are valid.Result of helpers for above node:
We expected
true
,false
andtrue
in this case. The node is still running in ECS. Also we don't understand howcloud?
can ever be false if one of the cloud provider helpers is true.Sometimes the
cloud
metadata is missing too, even though the node is running in EC2 or similar. We think this may have to do with moving a node from on-prem to the cloud.Checking the helper methods, it looks like they only check for the presence of the
azure
key and such. Maybe more robust checking is needed for edge cases like these.Chef Version
17.10.3
Platform Version
WSL Ubuntu 22.04.03 LTS
Replication Case
azure
orcloud
attributesThe text was updated successfully, but these errors were encountered: