From dd06ca07f19aeaf88f3683bcc853a3b2fdda7e07 Mon Sep 17 00:00:00 2001 From: Matt Fellows Date: Thu, 21 Apr 2016 16:01:39 +1000 Subject: [PATCH] Installing global modules into \WindowsPowershell\Modules --- provisioner/dsc/provisioner.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/provisioner/dsc/provisioner.go b/provisioner/dsc/provisioner.go index 4ff6989..4ef4b26 100644 --- a/provisioner/dsc/provisioner.go +++ b/provisioner/dsc/provisioner.go @@ -211,7 +211,7 @@ func (p *Provisioner) Provision(ui packer.Ui, comm packer.Communicator) error { // Upload all system-wide resources for _, path := range p.config.ResourcePaths { ui.Message(fmt.Sprintf("Uploading global DSC Resources from: %s", path)) - targetPath := fmt.Sprintf(`%s\%s`, `${env:SystemDrive}\WindowsPowershell\Modules`, filepath.Base(path)) + targetPath := fmt.Sprintf(`%s\%s`, `${env:programfiles}\WindowsPowershell\Modules`, filepath.Base(path)) if err := p.uploadDirectory(ui, comm, targetPath, path); err != nil { return fmt.Errorf("Error uploading global DSC Resource: %s", err) }