aboutsummaryrefslogtreecommitdiffhomepage
path: root/cmd/hpkg
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2025-08-18 16:47:23 +0900
committerOphestra <cat@gensokyo.uk>2025-08-18 16:48:01 +0900
commita3988c1a7725eb791795643e0810f03bab4572b3 (patch)
tree53284c7405b077a2f09c2b5b08117f85a21554d9 /cmd/hpkg
parent5db07140726e6e1bf615ed075e9a8b653508c2a7 (diff)
hst: rename net and abstract fields
This makes more sense and matches the container library. Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'cmd/hpkg')
-rw-r--r--cmd/hpkg/app.go20
-rw-r--r--cmd/hpkg/with.go2
2 files changed, 11 insertions, 11 deletions
diff --git a/cmd/hpkg/app.go b/cmd/hpkg/app.go
index 713a4fc7..e35dbf98 100644
--- a/cmd/hpkg/app.go
+++ b/cmd/hpkg/app.go
@@ -26,9 +26,9 @@ type appInfo struct {
// passed through to [hst.Config]
Userns bool `json:"userns,omitempty"`
// passed through to [hst.Config]
- Net bool `json:"net,omitempty"`
+ HostNet bool `json:"net,omitempty"`
// passed through to [hst.Config]
- Abstract bool `json:"abstract,omitempty"`
+ HostAbstract bool `json:"abstract,omitempty"`
// passed through to [hst.Config]
Device bool `json:"dev,omitempty"`
// passed through to [hst.Config]
@@ -85,14 +85,14 @@ func (app *appInfo) toHst(pathSet *appPathSet, pathname *container.Absolute, arg
Groups: app.Groups,
Container: &hst.ContainerConfig{
- Hostname: formatHostname(app.Name),
- Devel: app.Devel,
- Userns: app.Userns,
- Net: app.Net,
- Abstract: app.Abstract,
- Device: app.Device,
- Tty: app.Tty || flagDropShell,
- MapRealUID: app.MapRealUID,
+ Hostname: formatHostname(app.Name),
+ Devel: app.Devel,
+ Userns: app.Userns,
+ HostNet: app.HostNet,
+ HostAbstract: app.HostAbstract,
+ Device: app.Device,
+ Tty: app.Tty || flagDropShell,
+ MapRealUID: app.MapRealUID,
Filesystem: []hst.FilesystemConfigJSON{
{FilesystemConfig: &hst.FSBind{Source: pathSet.nixPath.Append("store"), Target: pathNixStore}},
{FilesystemConfig: &hst.FSBind{Source: pathSet.metaPath, Target: hst.AbsTmp.Append("app")}},
diff --git a/cmd/hpkg/with.go b/cmd/hpkg/with.go
index c6f3f22b..acb503d1 100644
--- a/cmd/hpkg/with.go
+++ b/cmd/hpkg/with.go
@@ -45,7 +45,7 @@ func withNixDaemon(
Container: &hst.ContainerConfig{
Hostname: formatHostname(app.Name) + "-" + action,
Userns: true, // nix sandbox requires userns
- Net: net,
+ HostNet: net,
SeccompFlags: seccomp.AllowMultiarch,
Tty: dropShell,
Filesystem: []hst.FilesystemConfigJSON{