Unverified Commit a5972fa1 authored by github-actions[bot]'s avatar github-actions[bot] Committed by GitHub
Browse files

Merge master into staging-next

parents 36afa30c 924dd674
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -11433,6 +11433,12 @@
    githubId = 15373888;
    name = "Claudius Holeksa";
  };
  keller00 = {
    name = "Mark Keller";
    email = "markooo.keller@gmail.com";
    github = "keller00";
    githubId = 8452750;
  };
  kennyballou = {
    email = "kb@devnulllabs.io";
    github = "kennyballou";
+2 −0
Original line number Diff line number Diff line
@@ -767,6 +767,8 @@
  rather than dotnet 6. For packages that still need dotnet 6, use
  `dotnet-sdk_6`, etc.

- torq has been removed because upstreamed went closed source.

## Other Notable Changes {#sec-release-24.11-notable-changes}

<!-- To avoid merge conflicts, consider adding your item at an arbitrary place in the list instead. -->
+21 −29
Original line number Diff line number Diff line
{ config, lib, pkgs, ... }:

with pkgs;
with lib;

let
  uid = config.ids.uids.mopidy;
  gid = config.ids.gids.mopidy;
  cfg = config.services.mopidy;

  mopidyConf = writeText "mopidy.conf" cfg.configuration;
  mopidyConf = pkgs.writeText "mopidy.conf" cfg.configuration;

  mopidyEnv = buildEnv {
    name = "mopidy-with-extensions-${mopidy.version}";
  mopidyEnv = pkgs.buildEnv {
    name = "mopidy-with-extensions-${pkgs.mopidy.version}";
    ignoreCollisions = true;
    paths = closePropagation cfg.extensionPackages;
    pathsToLink = [ "/${mopidyPackages.python.sitePackages}" ];
    nativeBuildInputs = [ makeWrapper ];
    paths = lib.closePropagation cfg.extensionPackages;
    pathsToLink = [ "/${pkgs.mopidyPackages.python.sitePackages}" ];
    nativeBuildInputs = [ pkgs.makeWrapper ];
    postBuild = ''
      makeWrapper ${mopidy}/bin/mopidy $out/bin/mopidy \
        --prefix PYTHONPATH : $out/${mopidyPackages.python.sitePackages}
      makeWrapper ${lib.getExe pkgs.mopidy} $out/bin/mopidy \
        --prefix PYTHONPATH : $out/${pkgs.mopidyPackages.python.sitePackages}
    '';
  };
in {
@@ -27,49 +23,47 @@ in {

    services.mopidy = {

      enable = mkEnableOption "Mopidy, a music player daemon";
      enable = lib.mkEnableOption "Mopidy, a music player daemon";

      dataDir = mkOption {
      dataDir = lib.mkOption {
        default = "/var/lib/mopidy";
        type = types.str;
        type = lib.types.str;
        description = ''
          The directory where Mopidy stores its state.
        '';
      };

      extensionPackages = mkOption {
      extensionPackages = lib.mkOption {
        default = [];
        type = types.listOf types.package;
        example = literalExpression "[ pkgs.mopidy-spotify ]";
        type = lib.types.listOf lib.types.package;
        example = lib.literalExpression "[ pkgs.mopidy-spotify ]";
        description = ''
          Mopidy extensions that should be loaded by the service.
        '';
      };

      configuration = mkOption {
      configuration = lib.mkOption {
        default = "";
        type = types.lines;
        type = lib.types.lines;
        description = ''
          The configuration that Mopidy should use.
        '';
      };

      extraConfigFiles = mkOption {
      extraConfigFiles = lib.mkOption {
        default = [];
        type = types.listOf types.str;
        type = lib.types.listOf lib.types.str;
        description = ''
          Extra config file read by Mopidy when the service starts.
          Later files in the list overrides earlier configuration.
        '';
      };

    };

  };

  ###### implementation

  config = mkIf cfg.enable {
  config = lib.mkIf cfg.enable {

    systemd.tmpfiles.settings."10-mopidy".${cfg.dataDir}.d = {
      user = "mopidy";
@@ -82,7 +76,7 @@ in {
      wants = [ "network-online.target" ];
      description = "mopidy music player daemon";
      serviceConfig = {
        ExecStart = "${mopidyEnv}/bin/mopidy --config ${concatStringsSep ":" ([mopidyConf] ++ cfg.extraConfigFiles)}";
        ExecStart = "${mopidyEnv}/bin/mopidy --config ${lib.concatStringsSep ":" ([mopidyConf] ++ cfg.extraConfigFiles)}";
        User = "mopidy";
      };
    };
@@ -90,7 +84,7 @@ in {
    systemd.services.mopidy-scan = {
      description = "mopidy local files scanner";
      serviceConfig = {
        ExecStart = "${mopidyEnv}/bin/mopidy --config ${concatStringsSep ":" ([mopidyConf] ++ cfg.extraConfigFiles)} local scan";
        ExecStart = "${mopidyEnv}/bin/mopidy --config ${lib.concatStringsSep ":" ([mopidyConf] ++ cfg.extraConfigFiles)} local scan";
        User = "mopidy";
        Type = "oneshot";
      };
@@ -105,7 +99,5 @@ in {
    };

    users.groups.mopidy.gid = gid;

  };

}
+9 −1
Original line number Diff line number Diff line
@@ -31,7 +31,15 @@ let
in
{
  options.services.victoriametrics = {
    enable = mkEnableOption "VictoriaMetrics is a fast, cost-effective and scalable monitoring solution and time series database.";
    enable = lib.mkOption {
      type = lib.types.bool;
      default = false;
      description = ''
        Whether to enable VictoriaMetrics in single-node mode.

        VictoriaMetrics is a fast, cost-effective and scalable monitoring solution and time series database.
      '';
    };
    package = mkPackageOption pkgs "victoriametrics" { };

    listenAddress = mkOption {
+25 −1
Original line number Diff line number Diff line
@@ -16,6 +16,7 @@ let

  cfg = config.services.monado;

  runtimeManifest = "${cfg.package}/share/openxr/1/openxr_monado.json";
in
{
  options.services.monado = {
@@ -35,6 +36,19 @@ in
      example = true;
    };

    forceDefaultRuntime = mkOption {
      type = types.bool;
      description = ''
        Whether to ensure that Monado is the active runtime set for the current
        user.

        This replaces the file `XDG_CONFIG_HOME/openxr/1/active_runtime.json`
        when starting the service.
      '';
      default = false;
      example = true;
    };

    highPriority =
      mkEnableOption "high priority capability for monado-service"
      // mkOption { default = true; };
@@ -68,6 +82,16 @@ in
          IPC_EXIT_ON_DISCONNECT = mkDefault "off";
        };

        preStart = mkIf cfg.forceDefaultRuntime ''
          XDG_CONFIG_HOME="''${XDG_CONFIG_HOME:-$HOME/.config}"
          targetDir="$XDG_CONFIG_HOME/openxr/1"
          activeRuntimePath="$targetDir/active_runtime.json"

          echo "Note: Replacing active runtime at '$activeRuntimePath'"
          mkdir --parents "$targetDir"
          ln --symbolic --force ${runtimeManifest} "$activeRuntimePath"
        '';

        serviceConfig = {
          ExecStart =
            if cfg.highPriority then
@@ -106,7 +130,7 @@ in
    hardware.graphics.extraPackages = [ pkgs.monado-vulkan-layers ];

    environment.etc."xdg/openxr/1/active_runtime.json" = mkIf cfg.defaultRuntime {
      source = "${cfg.package}/share/openxr/1/openxr_monado.json";
      source = runtimeManifest;
    };
  };

Loading