From 48edbfdc4b2aaf1eb9c7221679bb8515600e90ec Mon Sep 17 00:00:00 2001 From: "Wyatt J. Miller" Date: Sat, 18 Oct 2025 20:31:22 -0400 Subject: [PATCH] shairport service working systemd service works now ig --- modules/machine/cloud/configuration.nix | 2 +- modules/sound/shairport.nix | 13 +++++++++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/modules/machine/cloud/configuration.nix b/modules/machine/cloud/configuration.nix index 4aa3fc8..b76bbcc 100644 --- a/modules/machine/cloud/configuration.nix +++ b/modules/machine/cloud/configuration.nix @@ -18,7 +18,7 @@ in { imports = [ (import ../../apps/flatpak.nix { - inherit lib pkgs flatpakPackages; + inherit lib pkgs flatpakPackages userName; }) ../../apps/gaming.nix ../../apps/appimage.nix diff --git a/modules/sound/shairport.nix b/modules/sound/shairport.nix index 22ea614..6193496 100644 --- a/modules/sound/shairport.nix +++ b/modules/sound/shairport.nix @@ -1,7 +1,16 @@ -{pkgs, ...}: { +{ lib, pkgs, userName, ...}: { services.shairport-sync = { enable = pkgs.stdenv.isLinux; openFirewall = pkgs.stdenv.isLinux; - arguments = "-v -o pa"; + # arguments = "-v -o pa"; + }; + + systemd.services.shairport-sync = { + serviceConfig = { + User = lib.mkForce "${userName}"; + }; + environment = { + XDG_RUNTIME_DIR = "/run/user/1000"; + }; }; }