Skip to content
This repository has been archived by the owner on Jan 11, 2023. It is now read-only.

Commit

Permalink
Adds the missing logic for handling the preProvision extensions on Wi…
Browse files Browse the repository at this point in the history
…n agents. (#3367)
  • Loading branch information
adelina-t authored and jackfrancis committed Jun 26, 2018
1 parent c357400 commit 91cdfe9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
3 changes: 3 additions & 0 deletions parts/k8s/kuberneteswindowssetup.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -642,6 +642,9 @@ try
Write-Log "Set Internet Explorer"
Set-Explorer

Write-Log "Start preProvisioning script"
PREPROVISION_EXTENSION

Write-Log "Setup Complete, reboot computer"
Restart-Computer
}
Expand Down
5 changes: 5 additions & 0 deletions pkg/acsengine/template_generator.go
Original file line number Diff line number Diff line change
Expand Up @@ -598,6 +598,11 @@ func (t *TemplateGenerator) getTemplateFuncMap(cs *api.ContainerService) templat
if e != nil {
return ""
}
preprovisionCmd := ""
if profile.PreprovisionExtension != nil {
preprovisionCmd = makeAgentExtensionScriptCommands(cs, profile)
}
str = strings.Replace(str, "PREPROVISION_EXTENSION", escapeSingleLine(strings.TrimSpace(preprovisionCmd)), -1)
return fmt.Sprintf("\"customData\": \"[base64(concat('%s'))]\",", str)
},
"GetMasterSwarmModeCustomData": func() string {
Expand Down

0 comments on commit 91cdfe9

Please sign in to comment.