Need help Uxplay: No DNS-SD Server found

I want to stream my mac’s display to nixos and am trying uxplay. This is the error message I get when I install it then run the command uxplay:

UxPlay 1.73: An Open-Source AirPlay mirroring and audio-streaming server.
using network ports UDP 7011 6001 6000 TCP 7100 7000 7001
using system MAC address <redacted>
Initialized server socket(s)
*** ERROR: No DNS-SD Server found (DNSServiceRegister call returned kDNSServiceErr_Unknown)

I see many users online have issues with it as well but I didn’t find any solutions. I tried the following in my configuration:

      services.avahi.openFirewall = true;
      services.avahi.enable = true;
      networking.firewall.enable = lib.mkForce false;
2 Likes

The following Youtube video is useful to resolve this issue for me.

The code is in uxplay/uxplay.nix at 6364ecca328eab386db584e7fe03fd98a83c4a7e · TechsupportOnHold/uxplay · GitHub .

I also added plugins in my home-manager as following and it works.

++ (with pkgs.gst_all_1; [
  gst-libav
  gst-plugins-bad
  gst-plugins-base
  gst-plugins-good
  gst-plugins-ugly
  gst-vaapi # optional: hardware acceleration
  gstreamer
])