formated most nix funciton inputs

This commit is contained in:
William 2024-10-01 11:13:57 -03:00
parent 702d0f195b
commit 89c8784d49
48 changed files with 88 additions and 340 deletions

View file

@ -1,10 +1,4 @@
{ { ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
boot = { boot = {

View file

@ -1,10 +1,4 @@
{ { ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
console = { console = {

View file

@ -1,10 +1,4 @@
{ { ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
time.timeZone = "America/Bahia"; time.timeZone = "America/Bahia";

View file

@ -1,10 +1,4 @@
{ { ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
networking = { networking = {

View file

@ -1,10 +1,4 @@
{ { ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
nix = { nix = {

View file

@ -1,10 +1,4 @@
{ { pkgs, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
nixpkgs.config.allowUnfree = true; nixpkgs.config.allowUnfree = true;

View file

@ -1,10 +1,4 @@
{ { ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
security = { security = {

View file

@ -1,10 +1,4 @@
{ { ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
services = { services = {

View file

@ -1,10 +1,4 @@
{ { pkgs, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
users.users = { users.users = {

View file

@ -1,10 +1,4 @@
{ { pkgs, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
virtualisation.podman = { virtualisation.podman = {

View file

@ -1,10 +1,4 @@
{ { pkgs, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
boot = { boot = {

View file

@ -1,10 +1,4 @@
{ { ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
hardware = { hardware = {

View file

@ -1,6 +1,4 @@
{ { ... }:
...
}:
{ {
home-manager = { home-manager = {

View file

@ -1,9 +1,4 @@
{ { ... }:
config,
lib,
pkgs,
...
}:
{ {
environment.persistence.main = { environment.persistence.main = {

View file

@ -1,10 +1,4 @@
{ { inputs, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
environment.etc."channels/nixpkgs".source = inputs.nixpkgs.outPath; environment.etc."channels/nixpkgs".source = inputs.nixpkgs.outPath;

View file

@ -1,10 +1,4 @@
{ { pkgs, ... }:
inputs,
config,
pkgs,
lib,
...
}:
let let
kdepkgs = with pkgs.kdePackages; [ kdepkgs = with pkgs.kdePackages; [
ark ark

View file

@ -2,7 +2,6 @@
inputs, inputs,
config, config,
pkgs, pkgs,
lib,
... ...
}: }:

View file

@ -1,10 +1,4 @@
{ { ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
environment.sessionVariables = rec { environment.sessionVariables = rec {

View file

@ -1,10 +1,4 @@
{ { ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
virtualisation = { virtualisation = {

View file

@ -1,9 +1,4 @@
{ { ... }:
config,
lib,
pkgs,
...
}:
{ {
boot.initrd.systemd.services.recreate-root = { boot.initrd.systemd.services.recreate-root = {

View file

@ -1,10 +1,4 @@
{ { pkgs, ... }:
inputs,
config,
pkgs,
lib,
...
}:
let let
qubesnsh = pkgs.writeTextFile { qubesnsh = pkgs.writeTextFile {

View file

@ -1,10 +1,4 @@
{ { ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
imports = [ imports = [

View file

@ -1,10 +1,4 @@
{ { config, lib, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
services = { services = {

View file

@ -1,10 +1,4 @@
{ { config, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
virtualisation.oci-containers.containers."cinny" = { virtualisation.oci-containers.containers."cinny" = {

View file

@ -12,7 +12,6 @@
./nginx.nix ./nginx.nix
./paperless.nix ./paperless.nix
./searx.nix ./searx.nix
./security.nix
./services.nix ./services.nix
./pairdrop.nix ./pairdrop.nix
./users.nix ./users.nix

View file

@ -1,9 +1,5 @@
# 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, config,
pkgs,
lib, lib,
modulesPath, modulesPath,
... ...
@ -12,16 +8,20 @@
{ {
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ]; imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
boot.initrd.availableKernelModules = [ boot = {
initrd = {
availableKernelModules = [
"xhci_pci" "xhci_pci"
"ahci" "ahci"
"usbhid" "usbhid"
"usb_storage" "usb_storage"
"sd_mod" "sd_mod"
]; ];
boot.initrd.kernelModules = [ ]; kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ]; };
boot.extraModulePackages = [ ]; kernelModules = [ "kvm-intel" ];
extraModulePackages = [ ];
};
fileSystems."/" = { fileSystems."/" = {
device = "/dev/disk/by-uuid/31289617-1d84-4432-a833-680b52e88525"; device = "/dev/disk/by-uuid/31289617-1d84-4432-a833-680b52e88525";
@ -35,13 +35,9 @@
swapDevices = [ ]; swapDevices = [ ];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault true; networking.useDHCP = lib.mkDefault true;
# networking.interfaces.enp1s0.useDHCP = lib.mkDefault true;
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave"; powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
} }

View file

@ -1,10 +1,4 @@
{ { config, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
services = { services = {

View file

@ -1,10 +1,4 @@
{ { config, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
virtualisation.oci-containers.containers."librespeed" = { virtualisation.oci-containers.containers."librespeed" = {

View file

@ -1,10 +1,4 @@
{ { pkgs, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
services.minecraft-servers = { services.minecraft-servers = {

View file

@ -1,10 +1,4 @@
{ { config, pkgs, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
services = { services = {

View file

@ -1,10 +1,4 @@
{ { config, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
services.nginx = { services.nginx = {
@ -14,11 +8,30 @@
recommendedOptimisation = true; recommendedOptimisation = true;
recommendedProxySettings = true; recommendedProxySettings = true;
recommendedTlsSettings = true; recommendedTlsSettings = true;
virtualHosts."baduhai.dev" = { };
useACMEHost = "baduhai.dev";
forceSSL = true; security.acme = {
kTLS = true; acceptTerms = true;
root = inputs.homepage; defaults = {
email = "baduhai@proton.me";
dnsResolver = "1.1.1.1:53";
dnsProvider = "cloudflare";
credentialsFile = config.age.secrets.cloudflare.path;
};
certs."baduhai.dev" = {
extraDomainNames = [ "*.baduhai.dev" ];
}; };
}; };
boot.kernel.sysctl = {
"net.ipv4.ip_forward" = 1;
"net.ipv6.conf.all.forwarding" = 1;
};
age.secrets.cloudflare = {
file = ../../../secrets/cloudflare.age;
owner = "nginx";
group = "hosted";
};
} }

View file

@ -1,10 +1,4 @@
{ { config, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
virtualisation.oci-containers.containers."pairdrop" = { virtualisation.oci-containers.containers."pairdrop" = {

View file

@ -1,10 +1,4 @@
{ { config, lib, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
services = { services = {

View file

@ -1,5 +1,4 @@
{ {
inputs,
config, config,
pkgs, pkgs,
lib, lib,

View file

@ -1,33 +0,0 @@
{
inputs,
config,
pkgs,
lib,
...
}:
{
security.acme = {
acceptTerms = true;
defaults = {
email = "baduhai@proton.me";
dnsResolver = "1.1.1.1:53";
dnsProvider = "cloudflare";
credentialsFile = config.age.secrets.cloudflare.path;
};
certs."baduhai.dev" = {
extraDomainNames = [ "*.baduhai.dev" ];
};
};
boot.kernel.sysctl = {
"net.ipv4.ip_forward" = 1;
"net.ipv6.conf.all.forwarding" = 1;
};
age.secrets.cloudflare = {
file = ../../../secrets/cloudflare.age;
owner = "nginx";
group = "hosted";
};
}

View file

@ -1,14 +1,9 @@
{ { ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
services.postgresql.enable = true; services.postgresql.enable = true;
# TODO: remove when bug fux
# Workaround for upstream bug in NetworkManager-wait-online.service # Workaround for upstream bug in NetworkManager-wait-online.service
systemd.services.NetworkManager-wait-online.enable = false; systemd.services.NetworkManager-wait-online.enable = false;
} }

View file

@ -1,10 +1,4 @@
{ { ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
users = { users = {

View file

@ -1,10 +1,4 @@
{ { lib, ... }:
inputs,
config,
pkgs,
lib,
...
}:
let let
mkStringOption = mkStringOption =

View file

@ -1,10 +1,4 @@
{ { config, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
services = { services = {

View file

@ -1,10 +1,4 @@
{ { pkgs, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
boot.kernelPackages = pkgs.linuxPackages_hardened; boot.kernelPackages = pkgs.linuxPackages_hardened;

View file

@ -1,6 +1,4 @@
{ { ... }:
...
}:
{ {
home-manager = { home-manager = {
@ -10,4 +8,3 @@
users.user = import ../../../users/servers/user.nix; users.user = import ../../../users/servers/user.nix;
}; };
} }

View file

@ -1,10 +1,4 @@
{ { inputs, ... }:
inputs,
config,
pkgs,
lib,
...
}:
{ {
environment.etc."channels/nixpkgs".source = inputs.nixpkgs-stable.outPath; environment.etc."channels/nixpkgs".source = inputs.nixpkgs-stable.outPath;

View file

@ -4,6 +4,7 @@
pkgs, pkgs,
... ...
}: }:
with lib; with lib;
let let
cfg = config.services.qbittorrent; cfg = config.services.qbittorrent;

View file

@ -1,11 +1,8 @@
{ { pkgs, lib }:
stdenv,
pkgs,
lib,
}:
pkgs.stdenv.mkDerivation rec { pkgs.stdenv.mkDerivation {
name = "cros-ectool"; name = "cros-ectool";
nativeBuildInputs = with pkgs; [ nativeBuildInputs = with pkgs; [
cmake cmake
ninja ninja
@ -13,6 +10,7 @@ pkgs.stdenv.mkDerivation rec {
libusb libusb
libftdi1 libftdi1
]; ];
src = pkgs.fetchFromGitLab { src = pkgs.fetchFromGitLab {
domain = "gitlab.howett.net"; domain = "gitlab.howett.net";
owner = "DHowett"; owner = "DHowett";
@ -20,10 +18,12 @@ pkgs.stdenv.mkDerivation rec {
rev = "39d64fb0e79e874cfe9877af69158fc2520b1a80"; rev = "39d64fb0e79e874cfe9877af69158fc2520b1a80";
hash = "sha256-SHRnyqicFlviBDu3aH+uKVUstVxpIhZV6JSuZOgOwXU="; hash = "sha256-SHRnyqicFlviBDu3aH+uKVUstVxpIhZV6JSuZOgOwXU=";
}; };
installPhase = '' installPhase = ''
mkdir -p $out/bin mkdir -p $out/bin
cp src/ectool $out/bin/ectool cp src/ectool $out/bin/ectool
''; '';
meta = with lib; { meta = with lib; {
description = "ectool for ChromeOS devices"; description = "ectool for ChromeOS devices";
homepage = "https://gitlab.howett.net/DHowett/ectool"; homepage = "https://gitlab.howett.net/DHowett/ectool";

View file

@ -1,9 +1,4 @@
{ { pkgs, ... }:
config,
pkgs,
lib,
...
}:
{ {
home = { home = {

View file

@ -1,9 +1,4 @@
{ { pkgs, ... }:
config,
pkgs,
lib,
...
}:
{ {
programs = { programs = {

View file

@ -1,9 +1,4 @@
{ { pkgs, ... }:
config,
pkgs,
lib,
...
}:
{ {
fonts.fontconfig.enable = true; fonts.fontconfig.enable = true;

View file

@ -1,9 +1,4 @@
{ { config, ... }:
config,
pkgs,
lib,
...
}:
{ {
programs.wezterm = { programs.wezterm = {