mirror of
https://github.com/podman-container-tools/podman.git
synced 2026-08-05 00:15:44 +00:00
The podman module paths are moving from github.com/containers/podman to go.podman.io/podman. This will help with future mobility. Signed-off-by: Brent Baude <bbaude@redhat.com>
22 lines
498 B
Go
22 lines
498 B
Go
//go:build amd64 || arm64
|
|
|
|
package main
|
|
|
|
import (
|
|
"net/url"
|
|
|
|
"go.podman.io/podman/v6/internal/localapi"
|
|
)
|
|
|
|
func getMachineConn(connectionURI string, parsedConnection *url.URL) (string, error) {
|
|
mc, machineProvider, err := localapi.FindMachineByPort(connectionURI, parsedConnection)
|
|
if err != nil {
|
|
return "", err
|
|
}
|
|
|
|
podmanSocket, podmanPipe, err := mc.ConnectionInfo(machineProvider.VMType())
|
|
if err != nil {
|
|
return "", err
|
|
}
|
|
return extractConnectionString(podmanSocket, podmanPipe)
|
|
}
|