Support for deadnix pre-commit check

This commit is contained in:
Greg Hellings
2024-10-03 15:21:56 -05:00
parent 78c802d32c
commit 229188214f
46 changed files with 50 additions and 85 deletions
+1
View File
@@ -0,0 +1 @@
use flake
+1
View File
@@ -1,3 +1,4 @@
host
result
.pre-commit-config.yaml
.direnv
+3
View File
@@ -4,6 +4,9 @@
pre-commit-check = hooks.lib.${system}.run {
src = ./.;
hooks = {
deadnix.enable = true;
# Needs https://github.com/DeterminateSystems/flake-checker/pull/130
#flake-checker.enable = true;
nixpkgs-fmt.enable = true;
};
};
+1
View File
@@ -96,6 +96,7 @@
gzip
inject
inject-darwin
self'.checks.pre-commit-check.enabledPackages
tmux
vim
xonsh
+1 -1
View File
@@ -1,7 +1,7 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ config, lib, modulesPath, ... }:
{
imports =
+1 -1
View File
@@ -1,4 +1,4 @@
{ pkgs, config, ... }:
{ pkgs, ... }:
{
greg = {
+1 -1
View File
@@ -1,4 +1,4 @@
{ pkgs, ... }:
{ ... }:
{
programs.direnv = {
+1 -1
View File
@@ -1,4 +1,4 @@
{ pkgs, config, lib, ... }:
{ pkgs, config, ... }:
{
programs.xonsh = {
-2
View File
@@ -1,9 +1,7 @@
{ config, pkgs, lib, ... }:
let
gv = lib.hm.gvariant;
cfg = config.greg.gnome;
in
{
options.greg.gnome = lib.mkEnableOption "Enable Gnome support and settings";
+1 -1
View File
@@ -1,4 +1,4 @@
{ config, pkgs, lib, ... }:
{ config, lib, ... }:
let
cfg = config.programs.xonsh;
-4
View File
@@ -19,10 +19,6 @@ let
nixpkgs = import channel {
inherit system;
};
# Use this to include modules directly from a repo
nurNoPkg = import inputs.nurpkgs {
nurpkgs = nixpkgs;
};
in
channel.lib.nixosSystem {
inherit system;
+1 -1
View File
@@ -1,4 +1,4 @@
{ pkgs, config, ... }:
{ ... }:
{
imports = [
+1 -1
View File
@@ -1,7 +1,7 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ config, lib, modulesPath, ... }:
{
imports =
+1 -1
View File
@@ -2,7 +2,7 @@
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help).
{ config, pkgs, ... }:
{ pkgs, ... }:
{
imports = [
+1 -1
View File
@@ -1,7 +1,7 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ lib, modulesPath, ... }:
{
imports =
+1 -4
View File
@@ -1,8 +1,5 @@
{ config, pkgs, ... }:
{ pkgs, ... }:
let
service_list = [ "podman-home-assistant.service" ];
in
{
virtualisation.podman.enable = true;
+1 -1
View File
@@ -1,4 +1,4 @@
{ pkgs, config, ... }:
{ pkgs, ... }:
let
lan = "ens18";
lanIP = "10.42.1.5";
+1 -1
View File
@@ -2,7 +2,7 @@
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help).
{ config, pkgs, lib, inputs, overlays, ... }:
{ inputs, ... }:
let
wanInterface = "enp2s0";
lanInterface = "enp1s0";
+1 -1
View File
@@ -1,7 +1,7 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ config, lib, modulesPath, ... }:
{
imports =
+1 -1
View File
@@ -1,4 +1,4 @@
{ pkgs, config, ... }:
{ ... }:
{
# Bootloader.
+1 -1
View File
@@ -2,7 +2,7 @@
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help).
{ config, pkgs, agenix, ... }:
{ pkgs, ... }:
{
imports = [
+1 -1
View File
@@ -1,7 +1,7 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ config, lib, modulesPath, ... }:
{
imports =
-1
View File
@@ -1,6 +1,5 @@
{ pkgs, ... }:
let
wikiPasswordFile = "/var/mediawiki/passwordFile";
wikiHost = "wiki.icdm.lan";
kiwixport = 8080;
dependents = with pkgs; [
+1 -1
View File
@@ -1,7 +1,7 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ config, lib, modulesPath, ... }:
{
imports =
+1 -1
View File
@@ -1,7 +1,7 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ config, lib, modulesPath, ... }:
{
imports =
+1 -1
View File
@@ -1,4 +1,4 @@
{ config, pkgs, ... }:
{ ... }:
let
srcDomain = "src.thehellings.com";
+1 -1
View File
@@ -1,7 +1,7 @@
# Do not modify this file! It was generated by "nixos-generate-config"
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ config, lib, modulesPath, ... }:
{
imports = [
+1 -2
View File
@@ -2,11 +2,10 @@
# them by the following commands:
# nix run nixpkgs.matrix-synapse
# register_new_matrix_user -k "B9EoPr2WV9hzwc7uL2Sx1JmvCeKDEOGCpB0uginQcQtEH4wzRtkSIdo7lltrjSQa" http://localhost:8448
{ config, pkgs, ... }:
{ config, ... }:
let
domain = "${config.networking.domain}";
fqdn = "matrix.${domain}";
conn = "postgresql:///dendrite?sslmode=disable&host=/run/postgresql";
in
{
services.nginx = {
+1 -1
View File
@@ -1,4 +1,4 @@
{ config, pkgs, lib, ... }:
{ config, pkgs, ... }:
{
environment.systemPackages = [
+1 -1
View File
@@ -1,4 +1,4 @@
{ config, pkgs, lib, ... }:
{ lib, ... }:
{
imports = [
./ceph.nix
+1 -1
View File
@@ -1,7 +1,7 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ config, lib, modulesPath, ... }:
{
imports =
+2 -4
View File
@@ -1,7 +1,5 @@
{ config, pkgs, inputs, lib, ... }:
{ pkgs, ... }:
let
domain = "thehellings.com";
fqdn = "matrix.${domain}";
conn = "postgresql:///dendrite?sslmode=disable&host=/run/postgresql";
in
{
@@ -10,7 +8,7 @@ in
greg.containers.matrix = {
tailscale = true;
subnet = "204";
builder = { pkgs, config, ... }: {
builder = { config, ... }: {
networking.firewall.allowedTCPPorts = [ config.services.dendrite.httpPort ];
# Environment secrets
+1 -1
View File
@@ -1,4 +1,4 @@
{ pkgs, ... }:
{ ... }:
{
wsl = {
+1 -4
View File
@@ -1,7 +1,4 @@
{ pkgs, lib, ... }:
let
notDarwin = (! pkgs.stdenv.isDarwin);
in
{ pkgs, ... }:
{
# Enable flakes
nix = {
+3 -3
View File
@@ -5,7 +5,7 @@ let
where = j: "${config.services.syncthing.dataDir}/${j.dest}";
makeSyncFolders = name: job: {
makeSyncFolders = _: job: {
devices = [ "chronicles" ];
enable = true;
id = job.id;
@@ -14,7 +14,7 @@ let
type = "sendonly";
};
makeRestic = name: job:
makeRestic = _: job:
let
who = "${config.services.syncthing.user}:${config.services.syncthing.group}";
in
@@ -34,7 +34,7 @@ with lib; {
default = { };
type = with types; attrsOf (submodule (
{ name, config, options, ... }:
{ ... }:
{
options = {
src = mkOption {
+3 -1
View File
@@ -10,7 +10,7 @@ let
ensureUnitExists = c': name:
let
unitName = (builtins.elemAt (builtins.split "\\." name) 0);
#unitName = (builtins.elemAt (builtins.split "\\." name) 0);
in
if c'.systemd.services ? unitName
then name
@@ -393,6 +393,8 @@ in
"/run/wrappers" # `systemd.services.<name>.path` adds the `bin/` subdir of this
] ++ map ({ package, ... }: package) cephMonitoringSudoersCommandsAndPackages;
# Unused localOsdServiceName in the following line
# deadnix: skip
makeCephOsdSetupSystemdService = localOsdServiceName: osdConfig:
let
osdExistenceFile = "/var/lib/ceph/osd/.${toString osdConfig.id}.${osdConfig.uuid}.nix-existence";
+2 -2
View File
@@ -5,7 +5,7 @@ let
# Create a container with all our default settings
makeContainer = name: container:
makeContainer = _: container:
let
agekey = "/etc/ssh/agenix_key";
in
@@ -18,7 +18,7 @@ let
"${agekey}".hostPath = "/etc/ssh/ssh_host_ed25519_key"; # This is needed for agenix to
};
enableTun = container.tailscale;
config = { config, pkgs, ... }: {
config = { ... }: {
imports = [
inputs.agenix.nixosModules.default
inputs.self.modules.nixosModule
+1 -1
View File
@@ -8,7 +8,7 @@ in
options.greg.databases = lib.mkOption {
default = { };
type = with lib.types; attrsOf (submodule (
{ name, config, options, ... }: {
{ ... }: {
# Options reserved for future expansion
options = { };
}
+1 -1
View File
@@ -1,4 +1,4 @@
{ config, pkgs, inputs, lib, ... }:
{ config, pkgs, lib, ... }:
let
x =
+2 -2
View File
@@ -1,4 +1,4 @@
{ config, lib, pkgs, ... }:
{ config, lib, ... }:
let
cfg = config.greg.proxies;
@@ -38,7 +38,7 @@ with lib; {
'';
type = with types; attrsOf (submodule (
{ name, config, options, ... }:
{ ... }:
{
options = {
genAliases = mkOption {
+1 -1
View File
@@ -1,4 +1,4 @@
{ config, pkgs, lib, ... }:
{ config, lib, ... }:
let
cfg = config.greg.sway;
+1 -1
View File
@@ -1,4 +1,4 @@
{ config, lib, pkgs, ... }:
{ config, lib, ... }:
let
cfg = config.greg.syncthing;
+2 -9
View File
@@ -16,13 +16,6 @@ let
];
myPython = prev.python312.withPackages myPackages;
macOver = file: og:
if prev.stdenv.isDarwin then
(prev.callPackage file { }) else
prev."${og}";
buildFirefoxXpiAddon = final.nur.repos.rycee.lib.buildFirefoxXpiAddon;
is2405 = prev.lib.versionAtLeast prev.lib.version "24";
in
@@ -31,7 +24,7 @@ rec {
## Testing adding python packages in the correct manner
pythonPackagesExtensions = (prev.pythonPackagesExtensions or [ ]) ++ [
(python-final: python-prev:
(python-final: _:
let cp = python-final.callPackage; in {
django-rapyd-modernauth = cp ./django-rapyd-modernauth.nix { };
graypy = cp ./graypy.nix { };
@@ -58,7 +51,7 @@ rec {
brew = prev.callPackage ./homebrew.nix { };
copier = (if is2405 then
prev.copier.overridePythonAttrs
(old: {
(_: {
version = "9.1.0";
src = final.fetchFromGitHub {
owner = "copier-org";
-11
View File
@@ -10,17 +10,6 @@
, zipp
}:
let
pydeps = pypkgs: with pypkgs; [
click
django
python-dotenv
pytz
setuptools
sqlparse
zipp
];
in
buildPythonPackage rec {
pname = "django-rapyd-modernauth";
version = "0.0.4";
-4
View File
@@ -3,10 +3,6 @@
flake-utils.lib.eachDefaultSystemMap (system:
let
pkgs = (import nixunstable { inherit system; });
lib = pkgs.lib;
callPackage = pkgs.lib.callPackageWith pkgs;
python = pkgs.packages.python3;
cp = pkgs.packages.python3.pkgs.callPackage;
in
{
hms = pkgs.callPackage ./hms.nix {
-5
View File
@@ -7,11 +7,6 @@ let
jeremiah = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOjQjXq9WYU2Ki27BR9WwJ4ZruS/lJXbjC1b0Q42Adi0";
systems = [ genesis linode jude myself hosea jeremiah ];
user1 = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAAEAQDLQRq55JKqLifX+31kEXyuoB8gfM+5thAlgR7XLPvvdu6g2a5cCWyozQ1I2oGbPRfJtzcJ5ifM7Ii2PuqAj3MdYFLHBEDOhIpBBWme9Ts2YB9HJ4NorBvB4zEfJd0Q7k2MmylyeBOwdwGz3bVqPRDcJbxWFMDHqr33FEs6SXdfyAQ5SvhWGARI84qz8zUUdOp6M4e3aIGO3cx1gA+YzYQ4FbUtL8+m1NFO8VoNFMZBMf5q0iF/SgEu5bmGWUCePia6DvfeBFQ2/y4Y7WmOj980WE+JmFTkIvmGruMYeGI8FuDQ2JIIIcehddy9bQbPF4VlGnTFsHqJ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KEOb85lsIJ/SZ0bhsMl8bc9z33zY+bwv2NezG/aKVGrny4ZTAI1BKkZN/60L0yzJihyKamEa442jjnvG1jzC2wEtd/0gCGWScfZsQWqDu97spbeq8jrc67U9xqlGTrWyyNsCW2lpu26cQWWRC8ufl5zBNRDFDSYKceBaJ2+sx1GPj3YYdJSlTt5JvxNyBg0BGfGqCTd0w4IXF3KP9IZRWWAKPaOZcil2MRZwYhWEd7p+CtKVAL93uW0sE+0C13+iFMnBUkFBJ2dZH+tWpywCRYcrVNvrBlsHe2XniwBwvQHUFgKaQAB8upFTK1xBWTh2S+CVyNed/fckAUrPDj4sI2NERGcyPC5Oi6r0fUPtcWvKRfA/yXx5A0iNWc6acTqd5wwSO3s8rOCjIwdczZmkmnjAf3UKhmtDnwRd9rbO5Hanom80re9Dk0W+z9E2+70b9iYvZ60pbw+cG4WqEQnr02RS8hKvU0CsYFoDMTzV4snqTKNrl0IeD+Fmjl7oDkcC4YQbZd2902qVL3WHHvW+p0WQ1B/rk8BPVRYVmrUQbqwPFCQlmTe3Zy+LpqbWYemhQJGVSiEiioVNCc7pHO6RyWLCoEQKwKHAoNleKtkG94hT/d0z+1RYpB/nbJ51BPihK5EMlXbw/Hu1SVaaDLOSL6p greg@mm";
user_genesis_virt = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIFWPSFQT0AH77wrwRhiskcBS0w4ZakBRdJywYYBsnm3S greg@genesis";
user_ivr = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIMYzms+KIe5/bYF3uCyFjA5e1AgMPLIA3c4k417coqBe gregory.hellings@ls23003";
user_jude = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINnRc/kBhxcjpUtiRQY+BXnSObdp0jFL1395wAQxJip7 greg@jude";