diff options
Diffstat (limited to 'packaging/rpm')
| -rw-r--r-- | packaging/rpm/meshbay-node.spec | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/packaging/rpm/meshbay-node.spec b/packaging/rpm/meshbay-node.spec index 7052cff..5f28c52 100644 --- a/packaging/rpm/meshbay-node.spec +++ b/packaging/rpm/meshbay-node.spec @@ -40,8 +40,16 @@ Includes a local web UI at http://localhost:18000. %install %{python3} -m pip install --root %{buildroot} --no-index --find-links dist meshbay-node -# systemd user service (template) +# Two units, because there are two personas and one file cannot be both. +# +# The SYSTEM template carries User=%%i and is instantiated per person by root +# (`systemctl enable --now meshbay-node@alice`) — the server case. A *user* unit +# cannot carry User= at all: it already runs as its owner, and systemd refuses +# the file. This spec used to install the template into the user unit directory, +# where it could never have started. install -Dm644 packaging/systemd/meshbay-node.service \ + %{buildroot}%{_unitdir}/meshbay-node@.service +install -Dm644 packaging/systemd/meshbay-node-user.service \ %{buildroot}%{_userunitdir}/meshbay-node.service %files @@ -50,6 +58,7 @@ install -Dm644 packaging/systemd/meshbay-node.service \ %{python3_sitelib}/meshbay_node/ %{python3_sitelib}/meshbay_node-*.dist-info/ %{_bindir}/meshbay-node +%{_unitdir}/meshbay-node@.service %{_userunitdir}/meshbay-node.service %changelog |