feat(flatpak): let crafter-build run the host's flatpak
install and bundle run the host's flatpak and flatpak-builder, and the only way out of the sandbox to them is the Flatpak session helper, so the manifest grants --talk-name=org.freedesktop.Flatpak. crafter-build's own code uses it only through HostCommand, for the host's flatpak and flatpak-builder, but the permission is the whole sandbox's: every project.cpp crafter-build loads, its scripts, its dependencies' builds and the programs -r and test start can run host commands through flatpak-spawn --host as well. --filesystem=host already lets all of them arrange that, by writing ~/.bashrc or a systemd user unit; the permission makes it immediate, it does not make it possible. `flatpak update` lists it among the app's new permissions before it asks to proceed. The run flatpak and run install scripts of project.cpp still refuse inside the Flatpak, now for the reason that holds there: they run flatpak themselves, which the sandbox does not have.
This commit is contained in:
parent
eff250abb7
commit
71540b24aa
2 changed files with 11 additions and 1 deletions
|
|
@ -33,6 +33,16 @@ finish-args:
|
|||
- --device=all
|
||||
# lldb, and gdb and friends from the Sdk
|
||||
- --allow=devel
|
||||
# `crafter-build install` and `bundle` run the host's flatpak and
|
||||
# flatpak-builder, through :Platform's host helpers (RunHostFlatpak,
|
||||
# RunHostFlatpakBuilder and HostFlatpakUnavailable's probes, every command
|
||||
# line built by HostCommand); crafter-build's own code reaches the host
|
||||
# for nothing else. The permission is the whole sandbox's: a project.cpp,
|
||||
# its scripts, the builds of its dependencies and the programs -r and
|
||||
# test start can run host commands with it too. --filesystem=host already
|
||||
# lets them arrange that, by writing ~/.bashrc, so it makes running
|
||||
# something on the host immediate rather than possible.
|
||||
- --talk-name=org.freedesktop.Flatpak
|
||||
- --env=PATH=/app/bin:/usr/bin
|
||||
cleanup:
|
||||
- /share/man
|
||||
|
|
|
|||
Loading…
Reference in a new issue