Skip to content
This repository has been archived by the owner on Sep 26, 2021. It is now read-only.

Commit

Permalink
Allow localized names for Virtual Switch
Browse files Browse the repository at this point in the history
Signed-off-by: Gerard Braad <[email protected]>
  • Loading branch information
gbraad committed Jun 12, 2018
1 parent eae38c1 commit 5bc065d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/hyperv/hyperv.go
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ func (d *Driver) Create() error {
func (d *Driver) chooseVirtualSwitch() (string, error) {
if d.VSwitch == "" {
// Default to the first external switche and in the process avoid DockerNAT
stdout, err := cmdOut("(Hyper-V\\Get-VMSwitch -SwitchType External).Name")
stdout, err := cmdOut("[Console]::OutputEncoding = [Text.Encoding]::UTF8; (Hyper-V\\Get-VMSwitch -SwitchType External).Name")
if err != nil {
return "", err
}
Expand All @@ -287,7 +287,7 @@ func (d *Driver) chooseVirtualSwitch() (string, error) {
return switches[0], nil
}

stdout, err := cmdOut("(Hyper-V\\Get-VMSwitch).Name")
stdout, err := cmdOut("[Console]::OutputEncoding = [Text.Encoding]::UTF8; (Hyper-V\\Get-VMSwitch).Name")
if err != nil {
return "", err
}
Expand Down

0 comments on commit 5bc065d

Please sign in to comment.