зеркало из https://github.com/microsoft/oe-engine.git
implemented OS-dependend customData
This commit is contained in:
Родитель
7184bd0308
Коммит
57693790fd
|
@ -201,9 +201,8 @@
|
|||
"osProfile": {
|
||||
"computername": "[parameters('vmName')]",
|
||||
"adminUsername": "[variables('adminUsername')]",
|
||||
"adminPassword": "[parameters('adminPasswordOrKey')]",
|
||||
"adminPassword": "[if(equals(parameters('authenticationType'), 'password'), parameters('adminPasswordOrKey'), '')]",
|
||||
{{GetCustomData}}
|
||||
"customData": "[if(equals(parameters('osImageName'), 'WindowsServer_2016'), json('null'), {{GetCustomData}})]",
|
||||
"linuxConfiguration": "[if(equals(parameters('authenticationType'), 'password'), json('null'), variables('linuxConfiguration'))]",
|
||||
"windowsConfiguration": "[if(equals(parameters('osImageName'), 'WindowsServer_2016'), variables('windowsConfiguration'), json('null'))]"
|
||||
{{if .LinuxProfile.HasSecrets}}
|
||||
|
|
|
@ -139,7 +139,7 @@ func (t *TemplateGenerator) getTemplateFuncMap(cs *api.OpenEnclave) template.Fun
|
|||
"PROVISION_STR": script,
|
||||
"VALIDATION_STR": getProvisionScript(validationScript, nil),
|
||||
})
|
||||
return fmt.Sprintf("\"customData\": \"[base64(concat('#cloud-config\\n\\n', '%s'))]\",", str)
|
||||
return fmt.Sprintf("base64(concat('#cloud-config\\n\\n', '%s'))", str)
|
||||
},
|
||||
"GetAllowedVMSizes": func() string {
|
||||
return api.GetAllowedVMSizes()
|
||||
|
|
Загрузка…
Ссылка в новой задаче