wido commented on PR #14164:
URL: https://github.com/apache/cloudstack/pull/14164#issuecomment-5670284287
To add, this is how meta_data.json looked in the incorrect format and the
correct format:
```
{
"availability_zone": "AMS02",
"hostname": "VM-c38cdf78-5132-4e69-bd30-0a246165447e",
"uuid": "c38cdf78-5132-4e69-bd30-0a246165447e",
"keys": [
{
"type": "ssh",
"data": "ssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIFeMnwadvS7Z/sN0yCVnfcMgvxrmlNr2zElAMlFvbsP2\nssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIEPnHzS1LN+3VoXrUBWhRlIbWlSiqVdPynRNDy4bnLOn",
"name": "key"
}
],
"public_keys": {
"key": "ssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIFeMnwadvS7Z/sN0yCVnfcMgvxrmlNr2zElAMlFvbsP2\nssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIEPnHzS1LN+3VoXrUBWhRlIbWlSiqVdPynRNDy4bnLOn"
}
}
```
```
{
"availability_zone": "AMS02",
"hostname": "VM-baf04c61-ddbc-456b-b0bd-7bfdaee8d896",
"uuid": "baf04c61-ddbc-456b-b0bd-7bfdaee8d896",
"keys": [
{
"type": "ssh",
"data": "ssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIFeMnwadvS7Z/sN0yCVnfcMgvxrmlNr2zElAMlFvbsP2",
"name": "key0"
},
{
"type": "ssh",
"data": "ssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIEPnHzS1LN+3VoXrUBWhRlIbWlSiqVdPynRNDy4bnLOn",
"name": "key1"
}
],
"public_keys": {
"key0": "ssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIFeMnwadvS7Z/sN0yCVnfcMgvxrmlNr2zElAMlFvbsP2",
"key1": "ssh-ed25519
AAAAC3NzaC1lZDI1NTE5AAAAIEPnHzS1LN+3VoXrUBWhRlIbWlSiqVdPynRNDy4bnLOn"
}
}
```
This PR has been tested in real-life with a Ubuntu 26.04 VM using
ConfigDrive as it's cloud-init datasource.
```
root@VM-baf04c61-ddbc-456b-b0bd-7bfdaee8d896:~# cat
/etc/cloud/cloud.cfg.d/99-cloudstack.cfg
# cloud-init settings for Apache CloudStack guests.
#
# Installed as /etc/cloud/cloud.cfg.d/99-cloudstack.cfg so that the
# distribution's own /etc/cloud/cloud.cfg (system_info.distro, paths, package
# handling) stays in place and only the keys below are overridden.
# ConfigDrive is tried first: CloudStack attaches it as an ISO labeled
# 'config-2' and cloud-init reads it in the local stage, before networking.
# The CloudStack datasource (metadata served by the virtual router) is the
# fallback for networks without ConfigDrive.
datasource_list: [ConfigDrive, CloudStack, None]
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]