From: Alyssa Ross <hi@alyssa.is>
To: devel@spectrum-os.org
Cc: Demi Marie Obenour <demiobenour@gmail.com>
Subject: [PATCH v5 5/6] img/app: run Flatpak applications
Date: Mon, 1 Dec 2025 18:04:07 +0100 [thread overview]
Message-ID: <20251201170458.4186683-9-hi@alyssa.is> (raw)
In-Reply-To: <20251201170458.4186683-1-hi@alyssa.is>
Signed-off-by: Alyssa Ross <hi@alyssa.is>
---
v5: no change
v4: https://spectrum-os.org/lists/archives/spectrum-devel/20251201044534.977524-7-hi@alyssa.is/
img/app/default.nix | 1 +
img/app/file-list.mk | 1 +
| 5 +++++
img/app/image/etc/s6-rc/app/run | 14 +++++++++++++-
4 files changed, 20 insertions(+), 1 deletion(-)
create mode 100644 img/app/image/etc/flatpak/installations.d/extra.conf
diff --git a/img/app/default.nix b/img/app/default.nix
index 1eb3c9b..71e6fa0 100644
--- a/img/app/default.nix
+++ b/img/app/default.nix
@@ -49,6 +49,7 @@ let
name = "vm-fhs-env";
targetPkgs = pkgs: appimageTools.defaultFhsEnvArgs.targetPkgs pkgs ++ [
pkgs.fuse
+ pkgs.flatpak
(pkgs.busybox.override {
enableMinimal = true;
diff --git a/img/app/file-list.mk b/img/app/file-list.mk
index 6934975..4fbdec2 100644
--- a/img/app/file-list.mk
+++ b/img/app/file-list.mk
@@ -3,6 +3,7 @@
FILES = \
image/etc/dbus-1/session.conf \
+ image/etc/flatpak/installations.d/extra.conf \
image/etc/fstab \
image/etc/mdev.conf \
image/etc/mdev/iface \
--git a/img/app/image/etc/flatpak/installations.d/extra.conf b/img/app/image/etc/flatpak/installations.d/extra.conf
new file mode 100644
index 0000000..448902b
--- /dev/null
+++ b/img/app/image/etc/flatpak/installations.d/extra.conf
@@ -0,0 +1,5 @@
+# SPDX-License-Identifier: CC0-1.0
+# SPDX-FileCopyrightText: 2025 Alyssa Ross <hi@alyssa.is>
+
+[Installation "virtiofs"]
+Path=/run/virtiofs/virtiofs0/config/flatpak
diff --git a/img/app/image/etc/s6-rc/app/run b/img/app/image/etc/s6-rc/app/run
index 601926b..4b3b8d6 100755
--- a/img/app/image/etc/s6-rc/app/run
+++ b/img/app/image/etc/s6-rc/app/run
@@ -1,6 +1,6 @@
#!/bin/execlineb -P
# SPDX-License-Identifier: EUPL-1.2+
-# SPDX-FileCopyrightText: 2021, 2024 Alyssa Ross <hi@alyssa.is>
+# SPDX-FileCopyrightText: 2021, 2024-2025 Alyssa Ross <hi@alyssa.is>
export TMPDIR /run
@@ -25,6 +25,18 @@ foreground {
export LD_LIBRARY_PATH /lib64
/run/virtiofs/virtiofs0/config/run
}
+ flatpak {
+ s6-envdir -fnL /run/virtiofs/virtiofs0/config/params
+ multisubstitute {
+ importas -iu id id
+ importas -iu arch arch
+ importas -iu branch branch
+ importas -iu commit commit
+ importas -iu runtime_commit runtime-commit
+ }
+ flatpak run --installation=virtiofs --arch=${arch} --branch=${branch}
+ --commit=${commit} --runtime-commit=${runtime_commit} $id
+ }
nix {
if {
mount -t overlay
--
2.51.0
next prev parent reply other threads:[~2025-12-01 17:09 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-01 17:03 [PATCH v2 1/6] img/app: install fuse3 globally Alyssa Ross
2025-12-01 17:04 ` [PATCH 2/6] host/rootfs: set propagation of / to shared Alyssa Ross
2025-12-01 20:10 ` Alyssa Ross
2025-12-01 17:04 ` [PATCH v2 3/6] host/rootfs: create a per-VM mount namespace Alyssa Ross
2025-12-01 20:10 ` Alyssa Ross
2025-12-01 17:04 ` [PATCH v5 4/6] tools/mount-flatpak: init Alyssa Ross
2025-12-01 19:00 ` Demi Marie Obenour
2025-12-01 19:03 ` Demi Marie Obenour
2025-12-01 20:10 ` Alyssa Ross
2025-12-01 17:04 ` Alyssa Ross [this message]
2025-12-01 20:10 ` [PATCH v5 5/6] img/app: run Flatpak applications Alyssa Ross
2025-12-01 17:04 ` [PATCH v5 6/6] host/rootfs: add run-flatpak script Alyssa Ross
2025-12-01 20:10 ` Alyssa Ross
2025-12-01 20:10 ` [PATCH v2 1/6] img/app: install fuse3 globally Alyssa Ross
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20251201170458.4186683-9-hi@alyssa.is \
--to=hi@alyssa.is \
--cc=demiobenour@gmail.com \
--cc=devel@spectrum-os.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://spectrum-os.org/git/crosvm
https://spectrum-os.org/git/doc
https://spectrum-os.org/git/mktuntap
https://spectrum-os.org/git/nixpkgs
https://spectrum-os.org/git/spectrum
https://spectrum-os.org/git/ucspi-vsock
https://spectrum-os.org/git/www
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).