Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

override DefaultInitPath for FreeBSD #1496

Merged
merged 2 commits into from
Jun 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions pkg/config/config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@ package config

import (
"bytes"
"fmt"
"io"
"os"
"runtime"
"sort"
"strings"

Expand Down Expand Up @@ -509,6 +511,9 @@ image_copy_tmp_dir="storage"`

It("Test Capabilities call", func() {
// Given
if runtime.GOOS != "linux" {
Skip(fmt.Sprintf("capabilities not supported on %s", runtime.GOOS))
dfr marked this conversation as resolved.
Show resolved Hide resolved
}
// When
config, err := NewConfig("")
// Then
Expand Down
2 changes: 0 additions & 2 deletions pkg/config/default.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ const (
)

var (
// DefaultInitPath is the default path to the container-init binary.
DefaultInitPath = "/usr/libexec/podman/catatonit"
// DefaultInfraImage is the default image to run as infrastructure containers in pods.
DefaultInfraImage = ""
// DefaultRootlessSHMLockPath is the default path for rootless SHM locks.
Expand Down
7 changes: 7 additions & 0 deletions pkg/config/default_common.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
//go:build !freebsd
// +build !freebsd

package config

// DefaultInitPath is the default path to the container-init binary.
var DefaultInitPath = "/usr/libexec/podman/catatonit"
3 changes: 3 additions & 0 deletions pkg/config/default_freebsd.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
package config

// DefaultInitPath is the default path to the container-init binary.
var DefaultInitPath = "/usr/local/libexec/podman/catatonit"

func getDefaultCgroupsMode() string {
return "enabled"
}
Expand Down