aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/app/process.go
AgeCommit message (Collapse)Author
2025-10-29internal/outcome: rename from appOphestra
This is less ambiguous, and more accurately describes the purpose of the package. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-10-26internal/app/state: use absolute pathnamesOphestra
This is less error-prone and fits better into internal/app which already uses check.Absolute for all pathnames. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-10-25internal/app/state: use internal/lockedfileOphestra
This is a pretty solid implementation backed by robust tests, with a much cleaner interface. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-10-23hst/instance: store priv side pidOphestra
This can receive signals, so is more useful to the caller. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-10-23hst/instance: define instance stateOphestra
This is now part of the hst API. This change also improves identifier generation and serialisation. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-10-09message: relocate from containerOphestra
This package is quite useful. This change allows it to be imported without importing container. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-10-09internal/app: do not encode config earlyOphestra
Finalise no longer clobbers hst.Config. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-10-08internal/app: build container state in shimOphestra
This significantly decreases ipc overhead. Closes #3. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-10-07container/fhs: move pathname constantsOphestra
This allows referencing FHS pathnames without importing container. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-10-07container/check: move absolute pathnameOphestra
This allows use of absolute pathname values without importing container. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-10-05internal/app: do not offset base valueOphestra
This value is applied to the shim, it is incorrect to offset the base value as well. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-10-05system/wayland: hang up security-context-v1 internallyOphestra
This should have been an implementation detail and should not be up to the caller to close. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-10-05internal/app: modularise outcome finaliseOphestra
This is the initial effort of splitting up host and container side of finalisation for params to shim. The new layout also enables much finer grained unit testing of each step, as well as partition access to per-app state for each step. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-10-04system/dbus: dump buffer internallyOphestra
This should have been an implementation detail and should not be up to the caller to call it. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-09-29hst/enablement: move bits from systemOphestra
This is part of the hst API, should not be in the implementation package. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-09-29container: remove global msgOphestra
This frees all container instances of side effects. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-09-25internal: remove sys packageOphestra
This package is replaced by container/stub. Remove and replace it with unexported implementation for the upcoming test suite rewrite. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-09-24cmd/hsu: return hsurc idOphestra
The uid format is stable, this value is what caller has to obtain through hsu. Closes #14. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-09-24internal/app: unexport outcome, remove app structOphestra
The App struct no longer does anything, and the outcome struct is entirely opaque. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-09-24internal/app: do not return from shim startOphestra
The whole RunState ugliness and the other horrendous error handling conditions for internal/app come from an old design proposal for maintaining all app containers under the same daemon process for a user. The proposal was ultimately rejected but the implementation remained. It is removed here to alleviate internal/app from much of its ugliness and unreadability. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-09-16internal/app: compensate shim timeoutOphestra
This catches cases where the shim has somehow locked up, so it should wait out the full shim WaitDelay as well. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-09-15hst: replace internal/app errorOphestra
This turns out to still be quite useful across internal/app and its relatives. Perhaps a cleaner replacement for baseError. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-09-12internal/hlog: remove error wrappingOphestra
This was a stopgap solution that lasted for way too long. This finally removes it and prepares internal/app for some major changes. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-09-02system: update doc commands and remove mutexOphestra
The mutex is not really doing anything, none of these methods make sense when called concurrently anyway. The copylocks analysis is still satisfied by the noCopy struct. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-08-28internal/app: remove seal interfaceOphestra
This further cleans up the package for the restructure. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-04-12app: rename app implementation packageOphestra
Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-04-07app: improve shim process managementOphestra
This ensures a signal gets delivered to the process instead of relying on parent death behaviour. SIGCONT was chosen as it is the only signal an unprivileged process is allowed to send to processes with different credentials. A custom signal handler is installed because the Go runtime does not expose signal information other than which signal was received, and shim must check pid to ensure reasonable behaviour. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-03-25app: merge shim into app packageOphestra
Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-03-25system: optimise string formattingOphestra
Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-03-25app: run in native sandboxOphestra
Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-02-26app: print comp values earlyOphestra
Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-02-26app: define errors in a separate fileOphestra
Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-02-25fortify: improve handling of RevertErrOphestra
All this error wrapping is getting a bit ridiculous and I might want to do something about that somewhere down the line. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-02-21app: separate instance from process stateOphestra
This works better for the implementation. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-02-19app: defer system.I revertOphestra
Just returning an error after a successful call of commit will leave garbage behind with no way for the caller to clean them. This change ensures revert is always called after successful commit with at least per-process state enabled. Signed-off-by: Ophestra <cat@gensokyo.uk>
2025-02-19app: separate appSeal finalise methodOphestra
Signed-off-by: Ophestra <cat@gensokyo.uk>