From 25f0d8044a0e90fecf3da126fb2c3643c6d3dc32 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Thu, 31 Dec 2020 19:34:11 -0500 Subject: [PATCH] Minor refactors --- default.nix | 7 ++----- flake.nix | 2 +- modules/services/gitea.nix | 7 ++++--- 3 files changed, 7 insertions(+), 9 deletions(-) diff --git a/default.nix b/default.nix index 7f4af5b8..afed8b7c 100644 --- a/default.nix +++ b/default.nix @@ -19,11 +19,8 @@ with inputs; nix = { package = pkgs.nixFlakes; extraOptions = "experimental-features = nix-command flakes"; - nixPath = [ - "nixpkgs=${nixpkgs}" - "nixpkgs-unstable=${nixpkgs-unstable}" + nixPath = (mapAttrsToList (n: v: "${n}=${v}") inputs) ++ [ "nixpkgs-overlays=${dotFilesDir}/overlays" - "home-manager=${home-manager}" "dotfiles=${dotFilesDir}" ]; binaryCaches = [ @@ -45,7 +42,7 @@ with inputs; ## Some reasonable, global defaults # This is here to appease 'nix flake check' for generic hosts with no # hardware-configuration.nix or fileSystem config. - fileSystems."/".device = "/dev/disk/by-label/nixos"; + fileSystems."/".device = mkDefault "/dev/disk/by-label/nixos"; # Use the latest kernel boot.kernelPackages = pkgs.linuxPackages_5_9; diff --git a/flake.nix b/flake.nix index 3c205c16..e6a0fe24 100644 --- a/flake.nix +++ b/flake.nix @@ -25,7 +25,7 @@ nixos-hardware.url = "github:nixos/nixos-hardware"; }; - outputs = inputs @ { self, nixpkgs, nixpkgs-unstable, home-manager, ... }: + outputs = inputs @ { self, nixpkgs, nixpkgs-unstable, ... }: let inherit (lib) attrValues; inherit (lib.my) mapModules mapModulesRec mapHosts; diff --git a/modules/services/gitea.nix b/modules/services/gitea.nix index fcb38d91..9a4a6118 100644 --- a/modules/services/gitea.nix +++ b/modules/services/gitea.nix @@ -18,15 +18,16 @@ in { services.gitea = { enable = true; - log.level = "Info"; user = "git"; database.user = "git"; - useWizard = false; - disableRegistration = true; + disableRegistration = true; # We're assuming SSL-only connectivity cookieSecure = true; + # Only log what's important + log.level = "Error"; + settings.server.DISABLE_ROUTER_LOG = true; }; user.extraGroups = [ "gitea" ];