cmd/app: optional interactive shell
Test / Create distribution (push) Successful in 55s
Test / Sandbox (push) Successful in 3m4s
Test / Hakurei (push) Successful in 4m20s
Test / ShareFS (push) Successful in 4m19s
Test / Sandbox (race detector) (push) Successful in 5m36s
Test / Hakurei (race detector) (push) Successful in 6m51s
Test / Flake checks (push) Successful in 1m8s

Enabling this unconditionally causes the new configuration prompt to be shown when started from a terminal, and is generally less robust than not reading zshrc unless explicitly required.

Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
2026-06-20 19:08:47 +09:00
parent bd4b300ea6
commit 4e09241e5f
2 changed files with 10 additions and 5 deletions
+9 -4
View File
@@ -74,7 +74,7 @@ func parse(id string, base *check.Absolute, r io.Reader) (*hst.Config, error) {
Shell: shell,
Home: home,
Path: shell,
Args: []string{"zsh", "-ic"},
Args: []string{"zsh", "-c"},
Flags: hst.FCoverRun,
},
@@ -108,10 +108,11 @@ func parse(id string, base *check.Absolute, r io.Reader) (*hst.Config, error) {
}
c.Container.Args = append(c.Container.Args, s.Text(), "")
var flagGPU, flagSystemBus bool
var flagInteractive, flagGPU, flagSystemBus bool
flags := map[string]*bool{
"gpu": &flagGPU,
"system_bus": &flagSystemBus,
"interactive": &flagInteractive,
"gpu": &flagGPU,
"system_bus": &flagSystemBus,
}
for s.Scan() {
@@ -259,6 +260,10 @@ func parse(id string, base *check.Absolute, r io.Reader) (*hst.Config, error) {
return nil, err
}
if flagInteractive {
c.Container.Args[1] += "i"
}
if flagGPU {
c.Container.Filesystem = append(c.Container.Filesystem, []hst.FilesystemConfigJSON{
{FilesystemConfig: &hst.FSBind{
+1 -1
View File
@@ -112,7 +112,7 @@ talk com.canonical.Unity
Home: hst.AbsPrivateTmp.Append("home"),
Path: fhs.AbsRoot.Append("bin", "zsh"),
Args: []string{
"zsh", "-ic",
"zsh", "-c",
"exec Discord --ozone-platform-hint=wayland",
"",
},