Skip to content

Commit

Permalink
Search gvproxy with config.FindHelperBinary()
Browse files Browse the repository at this point in the history
Closes containers#11531

[NO TESTS NEEDED]

Signed-off-by: Hyeon Kim <[email protected]>
  • Loading branch information
simnalamburt committed Sep 14, 2021
1 parent b603c7a commit 072b061
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions pkg/machine/qemu/machine.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import (
"strings"
"time"

"github.com/containers/common/pkg/config"
"github.com/containers/podman/v3/pkg/machine"
"github.com/containers/podman/v3/pkg/rootless"
"github.com/containers/podman/v3/utils"
Expand Down Expand Up @@ -627,9 +628,12 @@ func CheckActiveVM() (bool, string, error) {
// startHostNetworking runs a binary on the host system that allows users
// to setup port forwarding to the podman virtual machine
func (v *MachineVM) startHostNetworking() error {
// TODO we may wish to configure the directory in containers common
binary := filepath.Join("/usr/libexec/podman/", machine.ForwarderBinaryName)
if _, err := os.Stat(binary); err != nil {
cfg, err := config.Default()
if err != nil {
return err
}
binary, err := cfg.FindHelperBinary(machine.ForwarderBinaryName, false)
if err != nil {
return err
}

Expand Down

0 comments on commit 072b061

Please sign in to comment.