forked from security/hakurei
internal/outcome: look up pipewire-pulse path
This is for setting up the pipewire-pulse container in shim, for #29. Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
@@ -66,6 +66,8 @@ type syscallDispatcher interface {
|
||||
// lookupGroupId calls [user.LookupGroup] and returns the Gid field of the resulting [user.Group] struct.
|
||||
lookupGroupId(name string) (string, error)
|
||||
|
||||
// lookPath provides exec.LookPath.
|
||||
lookPath(file string) (string, error)
|
||||
// cmdOutput provides the Output method of [exec.Cmd].
|
||||
cmdOutput(cmd *exec.Cmd) ([]byte, error)
|
||||
|
||||
@@ -140,6 +142,7 @@ func (direct) lookupGroupId(name string) (gid string, err error) {
|
||||
return
|
||||
}
|
||||
|
||||
func (direct) lookPath(file string) (string, error) { return exec.LookPath(file) }
|
||||
func (direct) cmdOutput(cmd *exec.Cmd) ([]byte, error) { return cmd.Output() }
|
||||
|
||||
func (direct) notifyContext(parent context.Context, signals ...os.Signal) (ctx context.Context, stop context.CancelFunc) {
|
||||
|
||||
Reference in New Issue
Block a user