nixos/nar-serve: remove with lib; (#343472)

This commit is contained in:
Daniel Nagy 2024-09-23 15:40:56 +02:00 committed by GitHub
parent 3accc97867
commit 201d35822e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,18 +1,18 @@
{ config, pkgs, lib, ... }:
with lib;
let
inherit (lib) mkOption types;
cfg = config.services.nar-serve;
in
{
meta = {
maintainers = [ maintainers.rizary maintainers.zimbatm ];
maintainers = with lib.maintainers; [ rizary zimbatm ];
};
options = {
services.nar-serve = {
enable = mkEnableOption "serving NAR file contents via HTTP";
enable = lib.mkEnableOption "serving NAR file contents via HTTP";
package = mkPackageOption pkgs "nar-serve" { };
package = lib.mkPackageOption pkgs "nar-serve" { };
port = mkOption {
type = types.port;
@ -48,7 +48,7 @@ in
};
};
config = mkIf cfg.enable {
config = lib.mkIf cfg.enable {
systemd.services.nar-serve = {
description = "NAR server";
after = [ "network.target" ];