The `gentoo-pipewire-launcher` script currently lacks any functionality to restart PipeWire and WirePlumber instances as required (e.g. to pick up configuration changes). i've just added a "Restarting PipeWire and WirePlumber" subsection to the PipeWire page on the wiki: https://wiki.gentoo.org/wiki/PipeWire#Restarting_PipeWire_and_WirePlumber but this feels Less Than Awesome from an end-user perspective. Instead, such commands could be called from within the `gentoo-pipewire-launcher` script if it was called with an argument of `restart`. Reproducible: Always
Yeah, fair point. Patches welcome if interested. Really, can't help but feel like the real fix is https://github.com/OpenRC/openrc/pull/573.
I've been running it in bwrap because that provides process tree cleanup functionality, though it's a bit heavyweight and unshare --kill-child would probably also do the job. IIRC someone already asked upstream a year ago if they'd consider making pipewire clean up its child processes on exit and got a non-answer, so we have to fend for ourselves one way or the other.
Created attachment 860978 [details, diff] Patch to add 'restart' functionality. Patch for `gentoo-pipewire-launcher` attached. Works For Me (tm). Please let me know of any required changes (including stylistic changes if needed - is there a Gentoo style guide for scripts?).
(In reply to Enne Eziarc from comment #2) > I've been running it in bwrap because that provides process tree cleanup > functionality, though it's a bit heavyweight and unshare --kill-child would > probably also do the job. > > IIRC someone already asked upstream a year ago if they'd consider making > pipewire clean up its child processes on exit and got a non-answer, so we > have to fend for ourselves one way or the other. Ah, thanks for the context. (In reply to Alexis from comment #3) > Created attachment 860978 [details, diff] [details, diff] > Patch to add 'restart' functionality. > > Patch for `gentoo-pipewire-launcher` attached. Works For Me (tm). Please let > me know of any required changes (including stylistic changes if needed - is > there a Gentoo style guide for scripts?). I'd missed you posted this! Could you ideally give it as a patch (git am-able patch to gentoo.git with a sign-off (note that signed-off-by allows consistent pseudonyms now))?
Created attachment 861171 [details, diff] Patch for application by git-am
(In reply to Sam James from comment #4) > I'd missed you posted this! > > Could you ideally give it as a patch (git am-able patch to gentoo.git with a > sign-off (note that signed-off-by allows consistent pseudonyms now))? Sure! Done. :-)
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=460a8f68d767b8a634aed94cd7478e384b456f1c commit 460a8f68d767b8a634aed94cd7478e384b456f1c Author: Alexis <flexibeast@gmail.com> AuthorDate: 2023-05-05 08:03:57 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2023-05-05 08:35:36 +0000 media-video/pipewire: gentoo-pipewire-launcher.in: Add restart functionality. Closes: https://bugs.gentoo.org/904851 Signed-off-by: Alexis <flexibeast@gmail.com> Signed-off-by: Sam James <sam@gentoo.org> .../pipewire/files/gentoo-pipewire-launcher.in-r1 | 52 +++ media-video/pipewire/pipewire-0.3.70-r1.ebuild | 474 +++++++++++++++++++++ media-video/pipewire/pipewire-9999.ebuild | 2 +- 3 files changed, 527 insertions(+), 1 deletion(-)
Thanks!
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5fa782429b4f607f8a1dc0e41e5cbe1bd94b35c3 commit 5fa782429b4f607f8a1dc0e41e5cbe1bd94b35c3 Author: Sam James <sam@gentoo.org> AuthorDate: 2023-05-11 00:48:00 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2023-05-11 00:48:00 +0000 media-video/pipewire: write error messages from gentoo-pipewire-launcher to stderr Thanks to Andrei Slavoiu and flexibeast. Bug: https://bugs.gentoo.org/904851 Closes: https://bugs.gentoo.org/906070 Signed-off-by: Sam James <sam@gentoo.org> media-video/pipewire/files/gentoo-pipewire-launcher.in-r1 | 8 ++++---- .../{pipewire-0.3.70-r1.ebuild => pipewire-0.3.70-r2.ebuild} | 0 2 files changed, 4 insertions(+), 4 deletions(-)