cmd/fshim: switch to setup pipe
All checks were successful
Tests / Go tests (push) Successful in 38s
Nix / NixOS tests (push) Successful in 5m43s

The socket-based approach is no longer necessary as fsu allows extra files and sudo compatibility is no longer relevant.

Signed-off-by: Ophestra Umiker <cat@ophivana.moe>
This commit is contained in:
2024-12-18 19:39:25 +09:00
parent 7be53a2438
commit 52f21a19f3
5 changed files with 52 additions and 205 deletions

View File

@@ -4,7 +4,6 @@ import (
"errors"
"fmt"
"os/exec"
"path"
"path/filepath"
"strings"
@@ -46,7 +45,6 @@ func (a *app) Start() error {
uint32(a.seal.sys.UID()),
a.seal.sys.user.as,
a.seal.sys.user.supp,
path.Join(a.seal.share, "shim"),
&shim0.Payload{
Argv: a.seal.command,
Exec: shimExec,
@@ -252,12 +250,6 @@ func (a *app) Wait() (int, error) {
}
}
if a.shim.Unwrap() == nil {
fmsg.VPrintln("fault before shim start")
} else {
a.shim.AbortWait(errors.New("shim exited"))
}
if a.seal.sys.needRevert {
if err := a.seal.sys.Revert(ec); err != nil {
return err.(RevertCompoundError)