mirror of
https://github.com/acepanel/panel.git
synced 2026-02-04 11:27:17 +08:00
fix: panic
This commit is contained in:
@@ -20,7 +20,7 @@ type Container struct {
|
||||
|
||||
func NewContainer(sock ...string) Container {
|
||||
if len(sock) == 0 {
|
||||
sock[0] = "/run/podman/podman.sock"
|
||||
sock = append(sock, "/run/podman/podman.sock")
|
||||
}
|
||||
cli, _ := client.NewClientWithOpts(client.WithHost("unix://"+sock[0]), client.WithAPIVersionNegotiation())
|
||||
return Container{
|
||||
|
||||
Reference in New Issue
Block a user