Skip to content

Commit

Permalink
refactor: interpolate the mount path
Browse files Browse the repository at this point in the history
  • Loading branch information
nixpig committed Dec 14, 2024
1 parent 88a7fb0 commit 4f15a32
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion container/container_init.go
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ func (c *Container) Init(reexec string, arg string, log *zerolog.Logger) error {

// TODO: align so the same mechanism is used for all namespaces?
if ns.Type == specs.MountNamespace {
reexecCmd.Env = append(reexecCmd.Env, fmt.Sprintf("gons_mnt=%s", ns.Path))
reexecCmd.Env = append(reexecCmd.Env, fmt.Sprintf("gons_%s=%s", ns.ToEnv(), ns.Path))
} else {
fd, err := syscall.Open(ns.Path, syscall.O_RDONLY, 0666)
if err != nil {
Expand Down

0 comments on commit 4f15a32

Please sign in to comment.