From a6089664ebbdbf3ba45239eeecfd77e638fca747 Mon Sep 17 00:00:00 2001 From: Sunil Mohan Adapa Date: Wed, 25 Jun 2025 13:14:46 -0700 Subject: [PATCH] privileged: Add /bin file for privileged daemon - So that it can be invoked easily from the command line and systemd service. Tests: - make install creates /usr/bin/freedombox-privileged daemon which can be run as root. Signed-off-by: Sunil Mohan Adapa Reviewed-by: Joseph Nuthalapati --- Makefile | 1 + bin/freedombox-privileged | 6 ++++++ pyproject.toml | 1 + 3 files changed, 8 insertions(+) create mode 100755 bin/freedombox-privileged diff --git a/Makefile b/Makefile index 4c1401ff6..0591aaa6a 100644 --- a/Makefile +++ b/Makefile @@ -98,6 +98,7 @@ install: rm -f $(DESTDIR)$${lib_dir}/plinth*.dist-info/COPYING.md && \ rm -f $(DESTDIR)$${lib_dir}/plinth*.dist-info/direct_url.json && \ $(INSTALL) -D -t $(BIN_DIR) bin/plinth + $(INSTALL) -D -t $(BIN_DIR) bin/freedombox-privileged # Actions $(INSTALL) -D -t $(DESTDIR)/usr/share/plinth/actions actions/actions diff --git a/bin/freedombox-privileged b/bin/freedombox-privileged new file mode 100755 index 000000000..6c487ef0a --- /dev/null +++ b/bin/freedombox-privileged @@ -0,0 +1,6 @@ +#!/usr/bin/python3 +# SPDX-License-Identifier: AGPL-3.0-or-later + +import plinth.privileged_daemon + +plinth.privileged_daemon.main() diff --git a/pyproject.toml b/pyproject.toml index 3b6dd22e1..90b7c8a35 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -103,6 +103,7 @@ build-backend = "setuptools.build_meta" [project.scripts] plinth = "plinth.__main__:main" +freedombox-privileged = "plinth.privileged_daemon:main" [tool.setuptools.dynamic] version = {attr = "plinth.__version__"}