vishesh92 commented on code in PR #9329:
URL: https://github.com/apache/cloudstack/pull/9329#discussion_r1672188006
##########
engine/storage/configdrive/src/main/java/org/apache/cloudstack/storage/configdrive/ConfigDriveBuilder.java:
##########
@@ -121,10 +126,16 @@ public static String buildConfigDrive(List<String[]>
vmData, String isoFileName,
File openStackFolder = new File(tempDirName +
ConfigDrive.openStackConfigDriveName);
- writeVendorAndNetworkEmptyJsonFile(openStackFolder);
- writeVmMetadata(vmData, tempDirName, openStackFolder,
customUserdataParams);
+ writeVendorEmptyJsonFile(openStackFolder);
+ writeNetworkData(nics, supportedServices, openStackFolder);
+ for (NicProfile nic: nics) {
Review Comment:
Let's assume you have attached two networks to a VM. One networks support
userdata with configdrive and the other one with Virtual Router.
If any of the network supports configDrive, we generate the configDrive for
user data and break the for loop.
We need to use all the nics attached to a VM here because while generating
`network_data.json`, it needs to know about other networks to generate the file.
--
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]