From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 08 08:11:37 2022 Received: (at 54986) by debbugs.gnu.org; 8 Dec 2022 13:11:37 +0000 Received: from localhost ([127.0.0.1]:56702 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3Gga-0002o3-Va for submit@debbugs.gnu.org; Thu, 08 Dec 2022 08:11:37 -0500 Received: from smtpmciv4.myservices.hosting ([185.26.107.240]:48080) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p3GgZ-0002nu-9L; Thu, 08 Dec 2022 08:11:35 -0500 Received: from mail1.netim.hosting (unknown [185.26.106.172]) by smtpmciv4.myservices.hosting (Postfix) with ESMTP id A58AF20775; Thu, 8 Dec 2022 14:11:33 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by mail1.netim.hosting (Postfix) with ESMTP id 65C0E80096; Thu, 8 Dec 2022 14:11:33 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at mail1.netim.hosting Received: from mail1.netim.hosting ([127.0.0.1]) by localhost (mail1-1.netim.hosting [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id Qm4M4if-MSeb; Thu, 8 Dec 2022 14:11:29 +0100 (CET) Received: from [192.168.1.239] (unknown [10.192.1.83]) (Authenticated sender: lumen@makinata.eu) by mail1.netim.hosting (Postfix) with ESMTPSA id 9CFC980093; Thu, 8 Dec 2022 14:11:29 +0100 (CET) Message-ID: <71f31a0d-cc58-a0e6-4aa4-b5c46513c835@makinata.eu> Date: Thu, 8 Dec 2022 13:11:29 +0000 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.5.1 From: mirai Subject: Re: [PATCH 0/2] services: mpd: Refactor MPD service To: Liliana Marie Prikler , 59866@debbugs.gnu.org References: <6e66967984d1bc22d8abf5dd4b07c1a20b4b06ee.camel@gmail.com> Content-Language: en-US In-Reply-To: <6e66967984d1bc22d8abf5dd4b07c1a20b4b06ee.camel@gmail.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 54986 Cc: 54986@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On 2022-12-07 18:27, Liliana Marie Prikler wrote: > Note that there is [1], which attempts to make it so that shepherd > endpoints can be specified in lieu of MPD endpoints. You don't need to > implement this logic – you are free to do so if you want to – but could > you make it so that there is an explicit endpoint abstraction that > would allow for extension later on? > > Cheers > > [1] https://issues.guix.gnu.org/54986 Hi, After reading issue #54986, regarding mpd escaping shepherd management, my guess is that there could be two issues at play here: * mpd.conf was serialized with pid_file [1]. The safest is to actually not serialize any unused directives and let MPD decide based on what's actually present. pid_file should only be set if MPD is to be launched as a "daemon process". [2] * But the service definition for MPD is launched with '--no-daemon' option as seen in [3], which could be triggering a bug in MPD. It's probably worth testing the combinations of having pid_file set and invoking --no-daemon. > but could > you make it so that there is an explicit endpoint abstraction that > would allow for extension later on? If I'm understanding correctly what [1] is about, I think this can be implemented through the 'extend' interface. See how certbot adds a nginx-server-configuration to a nginx-service-type through the 'extend' interface. For MPD, this would amount to appending the 'adresses' field with "adequately formatted" values. [1]: https://git.savannah.gnu.org/cgit/guix.git/tree/gnu/services/audio.scm?id=1b6172d5f6ca22f0fa02cd1335b1b90e9501b731#n116 [2]: https://mpd.readthedocs.io/en/latest/user.html#starting-and-stopping-mpd [3]: https://git.savannah.gnu.org/cgit/guix.git/tree/gnu/services/audio.scm?id=1b6172d5f6ca22f0fa02cd1335b1b90e9501b731#n145