Gitea fixes, formatting with nixpkgs-fmt

This commit is contained in:
Erwin Boskma 2022-04-27 00:21:19 +02:00
parent 7551396a58
commit 3c172be12d
Signed by: erwin
GPG key ID: 270B20D17394F7E5
68 changed files with 733 additions and 689 deletions

View file

@ -2,6 +2,7 @@ keys:
- &erwin b785a9688947edabb9ec8933ee7adefe1d943c7b - &erwin b785a9688947edabb9ec8933ee7adefe1d943c7b
- &loki a6e31f5ab2bf34ca3f614d81ed9d6ae54dbcb9f7 - &loki a6e31f5ab2bf34ca3f614d81ed9d6ae54dbcb9f7
- &drone 8eefb1f8c85704ca47aa226a692372b1fc4bb9bf - &drone 8eefb1f8c85704ca47aa226a692372b1fc4bb9bf
- &gitea ca0dba2f767679957879077fb8922c8ba16710be
creation_rules: creation_rules:
- path_regex: machines/loki/[^/]+\.yaml$ - path_regex: machines/loki/[^/]+\.yaml$
key_groups: key_groups:
@ -16,4 +17,5 @@ creation_rules:
- path_regex: machines/gitea/[^/]+\.yaml$ - path_regex: machines/gitea/[^/]+\.yaml$
key_groups: key_groups:
- pgp: - pgp:
- *erwin - *erwin
- *gitea

View file

@ -85,11 +85,11 @@
}, },
"emacs-overlay": { "emacs-overlay": {
"locked": { "locked": {
"lastModified": 1650746813, "lastModified": 1650946623,
"narHash": "sha256-RY2UXfjOmIE9xr/vSAxQOQQBjBgsr5pmA+NK5RCLpmg=", "narHash": "sha256-YGoR+ypDCii9Kl4bZ2NgOh0DLV6xSjcyM2rZsAWVdCM=",
"owner": "nix-community", "owner": "nix-community",
"repo": "emacs-overlay", "repo": "emacs-overlay",
"rev": "b3418d25f48c177c14e1fa677701067dc78936a6", "rev": "4356a0643b98868883425711daa02dde1290b2ed",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -166,11 +166,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1650478719, "lastModified": 1650920743,
"narHash": "sha256-308c2cM4hW9AW6dSQ080ycXGyEJGkG/OwOINkYL9Mnw=", "narHash": "sha256-7xxdtLp295HswhyEjr991QJsBFeadUo43NiAsHnQ5+8=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "93a69d07389311ffd6ce1f4d01836bbc2faec644", "rev": "223a73c2ba7d358b23666937cb13a59b31df511c",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -254,11 +254,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1650701402, "lastModified": 1650831523,
"narHash": "sha256-XKfstdtqDg+O+gNBx1yGVKWIhLgfEDg/e2lvJSsp9vU=", "narHash": "sha256-6pDZ08SAXsUx5rOP391x+TG39ENP/XA8VMa1tQvgEjc=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "bc41b01dd7a9fdffd32d9b03806798797532a5fe", "rev": "87d34a6b8982e901b8e50096b8e79ebc0e66cda0",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -385,11 +385,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1650681299, "lastModified": 1650941217,
"narHash": "sha256-JNvHHeeXDl3UnjWolMSbH2sWvhAYPfAutL815kZ6vFs=", "narHash": "sha256-rWpp8pKM9jYcvG7JiNAw+ITOlY20h8K83S3RQc9pY74=",
"owner": "oxalica", "owner": "oxalica",
"repo": "rust-overlay", "repo": "rust-overlay",
"rev": "d10f36b093459eb71ddcfedbab538c1ae3dfebb2", "rev": "b4cc9abdd42655b61325f3feb062cacc51a54de2",
"type": "github" "type": "github"
}, },
"original": { "original": {

224
flake.nix
View file

@ -69,77 +69,77 @@
}; };
}; };
outputs = { outputs =
self, { self
sops, , sops
ha-now-playing, , ha-now-playing
pamedia, , pamedia
... , ...
} @ inputs: } @ inputs:
with inputs; let with inputs; let
defSystem = system: baseConfig: defSystem = system: baseConfig:
nixpkgs.lib.nixosSystem { nixpkgs.lib.nixosSystem {
system = "${system}"; system = "${system}";
modules = [ modules = [
{_module.args.inputs = inputs;} { _module.args.inputs = inputs; }
{_module.args.self-overlay = self.overlay;} { _module.args.self-overlay = self.overlay; }
({...}: { ({ ... }: {
imports = imports =
builtins.attrValues self.nixosModules builtins.attrValues self.nixosModules
++ [ ++ [
{ {
nix.nixPath = ["nixpkgs=${nixpkgs}"]; nix.nixPath = [ "nixpkgs=${nixpkgs}" ];
nixpkgs.overlays = [ nixpkgs.overlays = [
self.overlay self.overlay
ha-now-playing.overlays.${system} ha-now-playing.overlays.${system}
pamedia.overlays.${system} pamedia.overlays.${system}
]; ];
} }
baseConfig baseConfig
home-manager.nixosModules.home-manager home-manager.nixosModules.home-manager
{home-manager.useUserPackages = true;} { home-manager.useUserPackages = true; }
]; ];
system.configurationRevision = nixpkgs.lib.mkIf (self ? rev) self.rev; system.configurationRevision = nixpkgs.lib.mkIf (self ? rev) self.rev;
nix.registry.nixpkgs.flake = nixpkgs; nix.registry.nixpkgs.flake = nixpkgs;
}) })
sops.nixosModules.sops sops.nixosModules.sops
]; ];
}; };
defContainer = system: baseConfig: defContainer = system: baseConfig:
nixos-generators.nixosGenerate { nixos-generators.nixosGenerate {
pkgs = nixpkgs.legacyPackages.${system}; pkgs = nixpkgs.legacyPackages.${system};
format = "proxmox-lxc"; format = "proxmox-lxc";
modules = [ modules = [
{_module.args.inputs = inputs;} { _module.args.inputs = inputs; }
{_module.args.self-overlay = self.overlay;} { _module.args.self-overlay = self.overlay; }
({...}: { ({ ... }: {
imports = imports =
builtins.attrValues self.nixosModules builtins.attrValues self.nixosModules
++ [ ++ [
{ {
nix.nixPath = ["nixpkgs=${nixpkgs}"]; nix.nixPath = [ "nixpkgs=${nixpkgs}" ];
nixpkgs.overlays = [ nixpkgs.overlays = [
self.overlay self.overlay
ha-now-playing.overlays.${system} ha-now-playing.overlays.${system}
pamedia.overlays.${system} pamedia.overlays.${system}
]; ];
} }
baseConfig baseConfig
home-manager.nixosModules.home-manager home-manager.nixosModules.home-manager
{home-manager.useUserPackages = true;} { home-manager.useUserPackages = true; }
]; ];
system.configurationRevision = nixpkgs.lib.mkIf (self ? rev) self.rev; system.configurationRevision = nixpkgs.lib.mkIf (self ? rev) self.rev;
nix.registry.nixpkgs.flake = nixpkgs; nix.registry.nixpkgs.flake = nixpkgs;
}) })
sops.nixosModules.sops sops.nixosModules.sops
]; ];
}; };
in in
{ {
overlay = import ./overlays; overlay = import ./overlays;
# overlay = final: prev: { # overlay = final: prev: {
@ -159,30 +159,36 @@
nixosConfigurations = { nixosConfigurations = {
vm1 = defSystem "x86_64-linux" { vm1 = defSystem "x86_64-linux" {
imports = [ imports = [
(import ./machines/vm1/configuration.nix {inherit self;}) (import ./machines/vm1/configuration.nix { inherit self; })
]; ];
}; };
vm2 = defSystem "x86_64-linux" { vm2 = defSystem "x86_64-linux" {
imports = [ imports = [
(import ./machines/vm2/configuration.nix {inherit self;}) (import ./machines/vm2/configuration.nix { inherit self; })
]; ];
}; };
loki = defSystem "x86_64-linux" { loki = defSystem "x86_64-linux" {
imports = [ imports = [
(import ./machines/loki/configuration.nix {inherit self;}) (import ./machines/loki/configuration.nix { inherit self; })
]; ];
}; };
drone = defSystem "x86_64-linux" { drone = defSystem "x86_64-linux" {
imports = [ imports = [
(import ./machines/drone/configuration.nix {inherit self;}) (import ./machines/drone/configuration.nix { inherit self; })
]; ];
}; };
proxy = defSystem "x86_64-linux" { proxy = defSystem "x86_64-linux" {
imports = [ imports = [
(import ./machines/proxy/configuration.nix {inherit self;}) (import ./machines/proxy/configuration.nix { inherit self; })
];
};
gitea = defSystem "x86_64-linux" {
imports = [
(import ./machines/gitea/configuration.nix { inherit self; })
]; ];
}; };
}; };
@ -190,56 +196,60 @@
nixosContainers = { nixosContainers = {
drone = defContainer "x86_64-linux" { drone = defContainer "x86_64-linux" {
imports = [ imports = [
(import ./machines/drone/configuration.nix {inherit self;}) (import ./machines/drone/configuration.nix { inherit self; })
]; ];
}; };
proxy = defContainer "x86_64-linux" { proxy = defContainer "x86_64-linux" {
imports = [ imports = [
(import ./machines/proxy/configuration.nix {inherit self;}) (import ./machines/proxy/configuration.nix { inherit self; })
]; ];
}; };
gitea = defContainer "x86_64-linux" { gitea = defContainer "x86_64-linux" {
imports = [ imports = [
(import ./machines/gitea/configuration.nix {inherit self;}) (import ./machines/gitea/configuration.nix { inherit self; })
]; ];
}; };
}; };
} }
// (flake-utils.lib.eachSystem ["aarch64-linux" "x86_64-linux"]) // (flake-utils.lib.eachSystem [ "aarch64-linux" "x86_64-linux" ])
( (
system: let system:
pkgs = import nixpkgs { let
inherit system; pkgs = import nixpkgs {
overlays = [ inherit system;
self.overlay overlays = [
ha-now-playing.overlays.${system} self.overlay
pamedia.overlays.${system} ha-now-playing.overlays.${system}
]; pamedia.overlays.${system}
config = { ];
allowUnsupportedSystem = true; config = {
allowUnfree = true; allowUnsupportedSystem = true;
allowUnfree = true;
};
}; };
}; in
in rec { rec {
packages = flake-utils.lib.flattenTree { packages = flake-utils.lib.flattenTree {
rofi-wayland = pkgs.rofi-wayland; rofi-wayland = pkgs.rofi-wayland;
nix-plugins = pkgs.nix-plugins; nix-plugins = pkgs.nix-plugins;
backscrub = pkgs.backscrub; backscrub = pkgs.backscrub;
};
apps = {
rofi-wayland = flake-utils.lib.mkApp {drv = packages.rofi-wayland;};
nix-plugins = flake-utils.lib.mkApp {drv = packages.nix-plugins;};
backscrub = flake-utils.lib.mkApp {drv = packages.backscrub;};
};
devShell = with pkgs;
mkShell {
nativeBuildInputs = [sops ssh-to-pgp];
packages = [sops];
}; };
}
); apps = {
rofi-wayland = flake-utils.lib.mkApp { drv = packages.rofi-wayland; };
nix-plugins = flake-utils.lib.mkApp { drv = packages.nix-plugins; };
backscrub = flake-utils.lib.mkApp { drv = packages.backscrub; };
};
devShell = with pkgs;
mkShell {
nativeBuildInputs = [ sops ssh-to-pgp ];
packages = [ sops ];
};
formatter = pkgs.nixpkgs-fmt;
}
);
} }

View file

@ -1,22 +1,21 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.alacritty; cfg = config.eboskma.programs.alacritty;
importYAML = name: yamlFile: (lib.importJSON ((pkgs.runCommandNoCC name {} '' importYAML = name: yamlFile: (lib.importJSON ((pkgs.runCommandNoCC name { } ''
mkdir -p $out mkdir -p $out
${pkgs.yaml2json}/bin/yaml2json < ${yamlFile} | ${pkgs.jq}/bin/jq -a '.' > $out/tmp.json ${pkgs.yaml2json}/bin/yaml2json < ${yamlFile} | ${pkgs.jq}/bin/jq -a '.' > $out/tmp.json
'') '').outPath
.outPath + "/tmp.json"));
+ "/tmp.json"));
theme = importYAML "theme" (builtins.fetchurl { theme = importYAML "theme" (builtins.fetchurl {
url = "https://raw.githubusercontent.com/dracula/alacritty/05faff15c0158712be87d200081633d9f4850a7d/dracula.yml"; url = "https://raw.githubusercontent.com/dracula/alacritty/05faff15c0158712be87d200081633d9f4850a7d/dracula.yml";
sha256 = "1366rvvni2shbqlcrbypjv4f7p7ccdr6bvr685jnj8ipwqjjb6rn"; sha256 = "1366rvvni2shbqlcrbypjv4f7p7ccdr6bvr685jnj8ipwqjjb6rn";
}); });
in { in
{
options.eboskma.programs.alacritty.enable = mkEnableOption "Enable alacritty"; options.eboskma.programs.alacritty.enable = mkEnableOption "Enable alacritty";
config = mkIf cfg.enable { config = mkIf cfg.enable {

View file

@ -1,12 +1,12 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.bat; cfg = config.eboskma.programs.bat;
in { in
{
options.eboskma.programs.bat = { options.eboskma.programs.bat = {
enable = mkEnableOption "enable bat"; enable = mkEnableOption "enable bat";
}; };

View file

@ -1,13 +1,13 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.dropbox; cfg = config.eboskma.programs.dropbox;
in { in
options.eboskma.programs.dropbox = {enable = mkEnableOption "activate dropbox";}; {
options.eboskma.programs.dropbox = { enable = mkEnableOption "activate dropbox"; };
config = mkIf cfg.enable { config = mkIf cfg.enable {
services.dropbox.enable = true; services.dropbox.enable = true;

View file

@ -1,12 +1,12 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.dunst; cfg = config.eboskma.programs.dunst;
in { in
{
options.eboskma.programs.dunst = { options.eboskma.programs.dunst = {
enable = mkEnableOption "activate dunst"; enable = mkEnableOption "activate dunst";
}; };

View file

@ -1,12 +1,12 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.electron; cfg = config.eboskma.programs.electron;
in { in
{
options.eboskma.programs.electron = { options.eboskma.programs.electron = {
enable = mkEnableOption "activate electron settings"; enable = mkEnableOption "activate electron settings";
wayland = mkEnableOption "set Wayland compatibility settings"; wayland = mkEnableOption "set Wayland compatibility settings";

View file

@ -1,26 +1,26 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.emacs; cfg = config.eboskma.programs.emacs;
emacs = with pkgs; ((emacsPackagesFor emacsPgtkNativeComp).emacsWithPackages (epkgs: [epkgs.emacsql epkgs.emacsql-sqlite])); emacs = with pkgs; ((emacsPackagesFor emacsPgtkNativeComp).emacsWithPackages (epkgs: [ epkgs.emacsql epkgs.emacsql-sqlite ]));
orgProtocolDesktop = pkgs.makeDesktopItem { orgProtocolDesktop = pkgs.makeDesktopItem {
name = "org-protocol"; name = "org-protocol";
desktopName = "Emacs Org Protocol Handler"; desktopName = "Emacs Org Protocol Handler";
icon = "emacs"; icon = "emacs";
categories = ["Development" "TextEditor"]; categories = [ "Development" "TextEditor" ];
keywords = ["org-protocol"]; keywords = [ "org-protocol" ];
type = "Application"; type = "Application";
exec = "${emacs}/bin/emacsclient -- %u"; exec = "${emacs}/bin/emacsclient -- %u";
terminal = false; terminal = false;
mimeTypes = ["x-scheme-handler/org-protocol"]; mimeTypes = [ "x-scheme-handler/org-protocol" ];
startupWMClass = "Emacs"; startupWMClass = "Emacs";
}; };
in { in
{
options.eboskma.programs.emacs = { options.eboskma.programs.emacs = {
enable = mkEnableOption "activate emacs"; enable = mkEnableOption "activate emacs";
daemon = mkOption { daemon = mkOption {

View file

@ -1,8 +1,7 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.firefox; cfg = config.eboskma.programs.firefox;
@ -46,7 +45,7 @@ with lib; let
) )
+ " %u"; + " %u";
icon = "firefox"; icon = "firefox";
categories = ["GNOME" "GTK" "Network" "WebBrowser"]; categories = [ "GNOME" "GTK" "Network" "WebBrowser" ];
mimeTypes = [ mimeTypes = [
"text/html" "text/html"
"text/xml" "text/xml"
@ -69,7 +68,8 @@ with lib; let
"X-MultipleArgs" = "false"; "X-MultipleArgs" = "false";
}; };
}; };
in { in
{
options.eboskma.programs.firefox = { options.eboskma.programs.firefox = {
enable = mkEnableOption "enable firefox"; enable = mkEnableOption "enable firefox";
work = mkOption { work = mkOption {
@ -99,6 +99,6 @@ in {
}; };
}; };
home.packages = [nonDefaultDesktop]; home.packages = [ nonDefaultDesktop ];
}; };
} }

View file

@ -1,12 +1,12 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.fish; cfg = config.eboskma.programs.fish;
in { in
{
options.eboskma.programs.fish = { options.eboskma.programs.fish = {
enable = mkEnableOption "Enable fish shell"; enable = mkEnableOption "Enable fish shell";
}; };
@ -14,7 +14,7 @@ in {
config = mkIf (cfg.enable) { config = mkIf (cfg.enable) {
programs.fish = { programs.fish = {
enable = true; enable = true;
functions = import ./functions.nix {inherit (pkgs) git;}; functions = import ./functions.nix { inherit (pkgs) git; };
plugins = [ plugins = [
{ {

View file

@ -1,4 +1,4 @@
{git}: { { git }: {
reload = { reload = {
body = '' body = ''
history --save history --save

View file

@ -1,12 +1,12 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.foot; cfg = config.eboskma.programs.foot;
in { in
{
options.eboskma.programs.foot = { options.eboskma.programs.foot = {
enable = mkEnableOption "activate foot"; enable = mkEnableOption "activate foot";
server = mkEnableOption "enable foot server"; server = mkEnableOption "enable foot server";

View file

@ -1,12 +1,12 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.git; cfg = config.eboskma.programs.git;
in { in
{
options.eboskma.programs.git = { options.eboskma.programs.git = {
enable = mkEnableOption "enable git"; enable = mkEnableOption "enable git";

View file

@ -1,12 +1,12 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.gpg; cfg = config.eboskma.programs.gpg;
in { in
{
options.eboskma.programs.gpg = { options.eboskma.programs.gpg = {
enable = mkEnableOption "enable gpg"; enable = mkEnableOption "enable gpg";
}; };

View file

@ -1,13 +1,13 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.neovim; cfg = config.eboskma.programs.neovim;
in { in
options.eboskma.programs.neovim = {enable = mkEnableOption "activate neovim";}; {
options.eboskma.programs.neovim = { enable = mkEnableOption "activate neovim"; };
config = mkIf cfg.enable { config = mkIf cfg.enable {
# unfortunately this does properly support a Lua based config # unfortunately this does properly support a Lua based config
@ -28,7 +28,7 @@ in {
# ''; # '';
# }; # };
home.packages = with pkgs; [neovim]; home.packages = with pkgs; [ neovim ];
xdg.configFile.nvim = { xdg.configFile.nvim = {
source = ./config; source = ./config;

View file

@ -1,13 +1,13 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.obs-studio; cfg = config.eboskma.programs.obs-studio;
in { in
options.eboskma.programs.obs-studio = {enable = mkEnableOption "activate obs-studio";}; {
options.eboskma.programs.obs-studio = { enable = mkEnableOption "activate obs-studio"; };
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.obs-studio = { programs.obs-studio = {

View file

@ -1,12 +1,12 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.rofi; cfg = config.eboskma.programs.rofi;
in { in
{
options.eboskma.programs.rofi.enable = mkEnableOption "Enable rofi"; options.eboskma.programs.rofi.enable = mkEnableOption "Enable rofi";
config = mkIf cfg.enable { config = mkIf cfg.enable {

View file

@ -1,13 +1,13 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.solvespace; cfg = config.eboskma.programs.solvespace;
in { in
options.eboskma.programs.solvespace = {enable = mkEnableOption "activate solvespace";}; {
options.eboskma.programs.solvespace = { enable = mkEnableOption "activate solvespace"; };
config = mkIf (cfg.enable) { config = mkIf (cfg.enable) {
home.packages = with pkgs; [ home.packages = with pkgs; [

View file

@ -1,13 +1,13 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.ssh; cfg = config.eboskma.programs.ssh;
in { in
options.eboskma.programs.ssh = {enable = mkEnableOption "activate ssh";}; {
options.eboskma.programs.ssh = { enable = mkEnableOption "activate ssh"; };
config = mkIf (cfg.enable) { config = mkIf (cfg.enable) {
programs.ssh = { programs.ssh = {

View file

@ -1,8 +1,7 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.sway; cfg = config.eboskma.programs.sway;
@ -10,7 +9,8 @@ with lib; let
swaylockcmd = "${pkgs.swaylock-effects}/bin/swaylock --ignore-empty-password --daemonize --show-failed-attempts --indicator-caps-lock --clock --image ~/.wallpapers/river-2560.png --fade-in 0.5 --scaling fill"; swaylockcmd = "${pkgs.swaylock-effects}/bin/swaylock --ignore-empty-password --daemonize --show-failed-attempts --indicator-caps-lock --clock --image ~/.wallpapers/river-2560.png --fade-in 0.5 --scaling fill";
# swaylockcmd = "${pkgs.swaylock}/bin/swaylock --ignore-empty-password --daemonize --show-failed-attempts --indicator-caps-lock --image ~/.wallpapers/river-2560.png --scaling fill"; # swaylockcmd = "${pkgs.swaylock}/bin/swaylock --ignore-empty-password --daemonize --show-failed-attempts --indicator-caps-lock --image ~/.wallpapers/river-2560.png --scaling fill";
rofiPower = pkgs.writeShellScriptBin "rofi-power" (builtins.readFile ./powermenu.sh); rofiPower = pkgs.writeShellScriptBin "rofi-power" (builtins.readFile ./powermenu.sh);
in { in
{
options.eboskma.programs.sway.enable = mkEnableOption "Enable sway"; options.eboskma.programs.sway.enable = mkEnableOption "Enable sway";
config = mkIf cfg.enable { config = mkIf cfg.enable {
@ -20,9 +20,9 @@ in {
modifier = mod; modifier = mod;
assigns = { assigns = {
"1" = [{app_id = "firefox";}]; "1" = [{ app_id = "firefox"; }];
"2" = [{app_id = "Alacritty";} {app_id = "foot";}]; "2" = [{ app_id = "Alacritty"; } { app_id = "foot"; }];
"3" = [{class = "Code";}]; "3" = [{ class = "Code"; }];
}; };
bars = [ bars = [
{ {
@ -78,12 +78,12 @@ in {
right = "o"; right = "o";
floating = { floating = {
criteria = [{app_id = "gnome-calculator";}]; criteria = [{ app_id = "gnome-calculator"; }];
modifier = mod; modifier = mod;
}; };
fonts = { fonts = {
names = ["Iosevka Nerd Font"]; names = [ "Iosevka Nerd Font" ];
style = "Regular"; style = "Regular";
size = 12.0; size = 12.0;
}; };
@ -287,7 +287,7 @@ in {
systemd.user.targets.tray = { systemd.user.targets.tray = {
Unit = { Unit = {
Description = "Home Manager System Tray"; Description = "Home Manager System Tray";
Requires = ["graphical-session-pre.target"]; Requires = [ "graphical-session-pre.target" ];
}; };
}; };
}; };

View file

@ -1,12 +1,12 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.tmux; cfg = config.eboskma.programs.tmux;
in { in
{
options.eboskma.programs.tmux = { options.eboskma.programs.tmux = {
enable = mkEnableOption "enable tmux"; enable = mkEnableOption "enable tmux";
}; };

View file

@ -1,13 +1,13 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , flake-inputs
flake-inputs, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.vscode; cfg = config.eboskma.programs.vscode;
in { in
{
options.eboskma.programs.vscode.enable = mkEnableOption "enable vscode"; options.eboskma.programs.vscode.enable = mkEnableOption "enable vscode";
config = mkIf cfg.enable { config = mkIf cfg.enable {

View file

@ -1,8 +1,7 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.waybar; cfg = config.eboskma.programs.waybar;
@ -14,7 +13,8 @@ with lib; let
if [[ ''${COUNT} != 0 ]]; then DISABLED=" ''${COUNT}"; fi if [[ ''${COUNT} != 0 ]]; then DISABLED=" ''${COUNT}"; fi
if ${pkgs.dunst}/bin/dunstctl is-paused | grep -q "false" ; then echo "''${ENABLED}"; else echo "''${DISABLED}"; fi if ${pkgs.dunst}/bin/dunstctl is-paused | grep -q "false" ; then echo "''${ENABLED}"; else echo "''${DISABLED}"; fi
''; '';
in { in
{
options.eboskma.programs.waybar.enable = mkEnableOption "Enable waybar"; options.eboskma.programs.waybar.enable = mkEnableOption "Enable waybar";
config = mkIf cfg.enable { config = mkIf cfg.enable {
@ -140,7 +140,7 @@ in {
phone = ""; phone = "";
portable = ""; portable = "";
car = ""; car = "";
default = ["" "奔" ""]; default = [ "" "奔" "" ];
}; };
on-click = "pavucontrol"; on-click = "pavucontrol";
}; };

View file

@ -1,13 +1,13 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.programs.zathura; cfg = config.eboskma.programs.zathura;
in { in
options.eboskma.programs.zathura = {enable = mkEnableOption "activate zathura";}; {
options.eboskma.programs.zathura = { enable = mkEnableOption "activate zathura"; };
config = mkIf (cfg.enable) { config = mkIf (cfg.enable) {
programs.zathura = { programs.zathura = {

View file

@ -4,7 +4,7 @@ let
}; };
lib = import "${krops}/lib"; lib = import "${krops}/lib";
pkgs = import "${krops}/pkgs" {}; pkgs = import "${krops}/pkgs" { };
source = name: source = name:
lib.evalSource [ lib.evalSource [
{ {
@ -25,7 +25,8 @@ let
source = source name; source = source name;
target = lib.mkTarget target; target = lib.mkTarget target;
}; };
in rec { in
rec {
# Deployments # Deployments
# Run with: # Run with:
@ -34,4 +35,5 @@ in rec {
loki = createHost "loki" "root@loki"; loki = createHost "loki" "root@loki";
drone = createHost "drone" "root@10.0.0.202"; drone = createHost "drone" "root@10.0.0.202";
proxy = createHost "proxy" "root@10.0.0.251"; proxy = createHost "proxy" "root@10.0.0.251";
gitea = createHost "gitea" "root@10.0.0.203";
} }

View file

@ -1,4 +1,4 @@
{self, ...}: { { self, ... }: {
imports = [ imports = [
./hardware-configuration.nix ./hardware-configuration.nix
../../users/root ../../users/root
@ -33,7 +33,7 @@
}; };
defaultGateway = "10.0.0.1"; defaultGateway = "10.0.0.1";
nameservers = ["10.0.0.254"]; nameservers = [ "10.0.0.254" ];
}; };
environment.noXlibs = true; environment.noXlibs = true;
@ -42,8 +42,8 @@
sops.defaultSopsFile = ./secrets.yaml; sops.defaultSopsFile = ./secrets.yaml;
sops.secrets = { sops.secrets = {
drone = {}; drone = { };
drone-runner = {}; drone-runner = { };
}; };
system.stateVersion = "21.11"; system.stateVersion = "21.11";

View file

@ -1,9 +1,8 @@
{ { config
config, , lib
lib, , pkgs
pkgs, , modulesPath
modulesPath, , ...
...
}: { }: {
imports = [ imports = [
(modulesPath + "/virtualisation/lxc-container.nix") (modulesPath + "/virtualisation/lxc-container.nix")

View file

@ -1,5 +1,6 @@
{ self, ... }@inputs: { { self, ... } @ inputs: {
imports = [ imports = [
./hardware-configuration.nix
../../users/root ../../users/root
../../users/erwin ../../users/erwin
]; ];
@ -9,7 +10,7 @@
nix-common.enable = true; nix-common.enable = true;
}; };
# boot.isContainer = true; boot.isContainer = true;
time.timeZone = "Europe/Amsterdam"; time.timeZone = "Europe/Amsterdam";
@ -22,15 +23,16 @@
interfaces = { interfaces = {
eth0 = { eth0 = {
ipv4.addresses = [ ipv4.addresses = [
{ address = "10.0.0.203"; {
prefixLength = 24; address = "10.0.0.201";
prefixLength = 24;
} }
]; ];
}; };
}; };
defaultGateway = "10.0.0.1"; defaultGateway = "10.0.0.1";
nameservers = ["10.0.0.254"]; nameservers = [ "10.0.0.254" ];
}; };
environment.noXlibs = true; environment.noXlibs = true;

View file

@ -0,0 +1,10 @@
{ config
, lib
, pkgs
, modulesPath
, ...
}: {
imports = [
(modulesPath + "/virtualisation/lxc-container.nix")
];
}

View file

@ -5,28 +5,48 @@ sops:
azure_kv: [] azure_kv: []
hc_vault: [] hc_vault: []
age: [] age: []
lastmodified: "2022-04-25T15:50:15Z" lastmodified: "2022-04-26T19:26:23Z"
mac: ENC[AES256_GCM,data:r+PbyDB1s0zBoczJVTaTnUvLw8Oqywul1zB7S8clXYtgWDSCIJ2igwupwmH2mYqEzTUutaKNjjAxbaerD8rrBgsJ1K1PSQwk6MawEskVwmdGbIdfCB8r0qHCNOE7pVRgTXyFxjEH6D9xxl/QJhVVTXXnZebR+r9q2SmJyazlFEg=,iv:lV6i7EKu6v0HORk1RhateMB9T0xMhROYKtd67M4fEJk=,tag:iTpNCUruB8Yd/5PlypdmQA==,type:str] mac: ENC[AES256_GCM,data:8KcUH12RqxkuX7MQpm4Xtl0YNUnhj/ef55ix8mb59ncLfjWauM7KlYVJg+La0FrqvWOFNNsMTYiBNlt/1KU9tqJs7kjzQQvhkcUDA6jAnFKtLCV6X8fd+3mon2UUL6eh5FDWjy3lTp45VrWNwTjC+LP1RAGGG7ie4tuI69PM1h0=,iv:SoU3hXDCZwJk4BLgjFU00rQUdqxlD5j8LcdQ8RZvbGs=,tag:9uveuZWgDesins8lk5w9Dw==,type:str]
pgp: pgp:
- created_at: "2022-04-25T15:49:31Z" - created_at: "2022-04-26T19:30:48Z"
enc: | enc: |
-----BEGIN PGP MESSAGE----- -----BEGIN PGP MESSAGE-----
hQIMA6BoiFpcAxNSAQ//cqGJB1/5LEEG9tmgwYoTAW3hhMaF3yDuMRQbYG8CKw8t hQIMA6BoiFpcAxNSARAAmVgrY+u/uozCxB3xTegvh2C+VOW4yxDBKGFfM5/NS3PR
ftrqUSltqoZi/9f7AHeQl82LnrdlHyHD3+uzcC1FYgYCU5OslD/IuvYBkVGXlvGh XneeBNRxJZ2BFsOnGtJZSsCkiD1FwVw9nYCnA1TCjw62gkHyJsvQziUM8WKrpIW0
kk7yBNSEsxVo2sPkrUPJzxapFcf1j2gm83WZ4vTUQ8Mn5UYmGBNmVw4cLtO/R732 RXHllXawOW7Lb0faUcTRF90Z//kVfk4o33Xs895IK+mk+iRpLdE0RrINBfZ7jb0y
ZhvvLePeF2Za79UxEKIkbh2CWNNA80PLZt8pLUsl+HXnWxNep6fDdwrC6GdU3C8o OJ93wJ0CL7A5KtltUBthX+POqI12bbj7hnUtz05mfpQG6PcnRwMHJBUk0JPo4s4H
qcHN7+JGZdDYFqD0bsxpHFYcbg8OWajFJ4vbx9JHSNfjxXRqzaWr+3I93N/aMra/ 8ksJlPRrbwi7JU5XQTo7SDTp/IwbXbewCylkS7nt05znIOFIejC22XEv8w0XPX8p
vXyqeRaqowXx9hL2lIAU2Pvpe79+YMeYm3WgEI0ytBz7o86majq3DQ3+XjESIpoy ZwQxPvOrXb4f1PDFgv65ej2aXREc7sidwqg8hUiBsKBuxRjFQFzLcwhNzAKwv30s
5hNC+cgFiuBUE6e1lBq3812ycsH+HPtha2ppsyr5CX1Fjc63hkszU0bH6UL1jUVk Nrj4yTMn2qNIjhsfHfMgRpm/iwvpsAFWFUqGkwb3gs3V7PjOidRMB4xDY1QV9Pae
hUAEuLiKADnwPJK1NGrXHqyfEYhIAFkCvEgBK5zoCkcuQ/r2CsO8GfQdOPDwVKcC b8z18S4cFIh69Aev3fiDzopL5xF7ZBcayIjwC6RkhYzcedkz5oPl2tqqkJCiPQe9
WLHQU9hq66iCLTd9IxVfOn5YcMjHk6Ie5Dam7cbF3pVAcXrKneYgNK4kdh7aBOqe ohxGF8m/9k/OhQRKl8HURybMyX7SwAXA9Tx1dNbb2xbPNaFXSBKxpF7B2k3kD/pQ
dasqr/HNJ4Fi15lrVyx2g8c8mb68AbmTCydPX5tZ3RCIc0r8i4iEbYS0Ny8jVPZp skuuHDl2z/deoD0Gu75+Svvb6jv82P3+KL9waaxrnfQQ3avX6hIQ9zF34jTxHbtr
6qzI3qo0LnrnMaqqKiJAGH2x3y4bJUlrlab3tV0Kou7e2oM4WhY3jVFXtdAV7+HS UHAxEtuuIdER8756fWtgWshpdY2rWQ54flT6nlhtsNN1Io/flXdeof6S3hDiKAnS
XgGGtcTnOE6cSrFRZCSCCzsRrvgDY3NNrrcVBayeCHG+OLqgiHngReG9CdbMzi9E XgEAVMKweW8Q2OhGhJZSEnP8IpRsPuGu3G1v8/L+lzJEK4edvUr9IgqGUq7Iqeql
8yIxWF3/8kbKqru6TSheHgOu1v0q/RnCAEqukRynw/Ze8t2/tzGkzETgRMcCoDU= 7+sw+jFzJPsPhiFpvZx1pB1RGS50q6O/Ch8/AMK7SvYD6oSASYfa/ifzAZSapiE=
=q/Xc =r/Wn
-----END PGP MESSAGE----- -----END PGP MESSAGE-----
fp: b785a9688947edabb9ec8933ee7adefe1d943c7b fp: b785a9688947edabb9ec8933ee7adefe1d943c7b
- created_at: "2022-04-26T19:30:48Z"
enc: |
-----BEGIN PGP MESSAGE-----
hQIMA7iSLIuhZxC+AQ/+Pr6/373P/TKxh3S1rg2SwIlwJ6pZo4E4JZBmCQ+YTZNz
WOg9WLUrMVAgax6dDTf+GPPCLphI7SfQjPqpHEOw/eUtZhSqmcq61no0gVyDgv5s
KHPrary79dVG7xw9i/ipc8LPc8hujeXHD4hzv2iYlod4LhjPwR4WsxaQJ7fbaU5V
V7Gu4wzdoiOTl1fthXaUAqjgJ/iRlQhML5B46dMVg5E7g7GKmJjPuBhDWIAz+/2Y
fNY5dWL7B5R67zFmrxUUa9Wbr1SvEViR4bKaUURMhixzgWAxgQ79zR4B3J1D+tW/
2TnpPgP2b5ikMKbUFBEX7x/oGmvVn4DJcDwQEM1X5+nMOpT7j4cx0NOnhUkJNfdW
VJK2bN/XBlfy9SnAz/nzleKzO+p27LvBfnyvC4fC9ZySNfVWdcDaqCRbF0mfHWB1
2C0HfEAQe7X7Vzpc3w+FyyZuQRNixTQjl2pouJIVWQOUFGy5Xn5yZgWrb93day9K
Q2zem+jMHQQpDc/KPSh1qIgboAh7UnxhfKJCUUortL6eMOL7UQi42qautDngl93D
opBSf2my+gqFajV6Y0vYO9MSGFd92XLwqQXnJMPEHm/aDsQRxW8mf71ZMu1iMUns
IU8nPgki2VC3Z+OnSYdUv8aSY5K341xODfntmrcdO/Q1dvsXEyPtZ81BQn4nY2jS
WAH3bwUphfdA/PNBRTGrYp/TiTdhj1cGtgyjY1QgIA2i8PTRAD4nk3kY6qwchUJE
Mjx0i74gMqFOZ81iFS1ohiya2zhP5mwbLzIP4hdt5J9UvDozhS52VE0=
=vu1S
-----END PGP MESSAGE-----
fp: ca0dba2f767679957879077fb8922c8ba16710be
unencrypted_suffix: _unencrypted unencrypted_suffix: _unencrypted
version: 3.7.2 version: 3.7.2

View file

@ -1,5 +1,5 @@
{self, ...}: { { self, ... }: {
imports = [./hardware-configuration.nix ../../users/erwin ../../users/root]; imports = [ ./hardware-configuration.nix ../../users/erwin ../../users/root ];
eboskma = { eboskma = {
# backscrub.enable = true; # backscrub.enable = true;
@ -28,9 +28,9 @@
}; };
networking = { networking = {
enable = true; enable = true;
dhcpInterfaces = ["enp4s0"]; dhcpInterfaces = [ "enp4s0" ];
hosts = { hosts = {
"10.0.0.252" = ["pve.datarift.nl"]; "10.0.0.252" = [ "pve.datarift.nl" ];
}; };
}; };
nix-common = { nix-common = {

View file

@ -1,21 +1,20 @@
# Do not modify this file! It was generated by nixos-generate-config # Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes # and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead. # to /etc/nixos/configuration.nix instead.
{ { config
config, , lib
lib, , pkgs
pkgs, , modulesPath
modulesPath, , ...
...
}: { }: {
imports = [ imports = [
(modulesPath + "/installer/scan/not-detected.nix") (modulesPath + "/installer/scan/not-detected.nix")
]; ];
boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "ahci" "usb_storage" "usbhid" "sd_mod"]; boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usb_storage" "usbhid" "sd_mod" ];
boot.initrd.kernelModules = []; boot.initrd.kernelModules = [ ];
boot.kernelModules = ["kvm-amd" "apple-mfi-fastcharge"]; boot.kernelModules = [ "kvm-amd" "apple-mfi-fastcharge" ];
boot.extraModulePackages = []; boot.extraModulePackages = [ ];
fileSystems."/" = { fileSystems."/" = {
device = "/dev/disk/by-uuid/42065c7e-d0aa-4de8-a913-014cf59d48ac"; device = "/dev/disk/by-uuid/42065c7e-d0aa-4de8-a913-014cf59d48ac";
@ -32,9 +31,8 @@
fsType = "ext4"; fsType = "ext4";
}; };
swapDevices = [{device = "/dev/disk/by-uuid/d93788f7-1b94-4687-8313-055d17f42b7e";}]; swapDevices = [{ device = "/dev/disk/by-uuid/d93788f7-1b94-4687-8313-055d17f42b7e"; }];
# high-resolution display # high-resolution display
hardware.video.hidpi.enable = lib.mkDefault true; hardware.video.hidpi.enable = lib.mkDefault true;
} }

View file

@ -1,4 +1,4 @@
{self, ...}: { { self, ... }: {
imports = [ imports = [
./hardware-configuration.nix ./hardware-configuration.nix
../../users/root ../../users/root
@ -33,7 +33,7 @@
}; };
defaultGateway = "10.0.0.1"; defaultGateway = "10.0.0.1";
nameservers = ["10.0.0.254"]; nameservers = [ "10.0.0.254" ];
}; };
environment.noXlibs = true; environment.noXlibs = true;
@ -41,7 +41,7 @@
services.openssh.enable = true; services.openssh.enable = true;
sops.defaultSopsFile = ./secrets.yaml; sops.defaultSopsFile = ./secrets.yaml;
sops.secrets = {}; sops.secrets = { };
system.stateVersion = "21.11"; system.stateVersion = "21.11";
} }

View file

@ -1,9 +1,8 @@
{ { config
config, , lib
lib, , pkgs
pkgs, , modulesPath
modulesPath, , ...
...
}: { }: {
imports = [ imports = [
(modulesPath + "/virtualisation/lxc-container.nix") (modulesPath + "/virtualisation/lxc-container.nix")

View file

@ -1,5 +1,5 @@
{self, ...}: { { self, ... }: {
imports = [./hardware-configuration.nix]; imports = [ ./hardware-configuration.nix ];
eboskma = { eboskma = {
desktop = { desktop = {

View file

@ -1,21 +1,20 @@
# Do not modify this file! It was generated by nixos-generate-config # Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes # and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead. # to /etc/nixos/configuration.nix instead.
{ { config
config, , lib
lib, , pkgs
pkgs, , modulesPath
modulesPath, , ...
...
}: { }: {
imports = [ imports = [
(modulesPath + "/profiles/qemu-guest.nix") (modulesPath + "/profiles/qemu-guest.nix")
]; ];
boot.initrd.availableKernelModules = ["ahci" "xhci_pci" "virtio_pci" "sr_mod" "virtio_blk"]; boot.initrd.availableKernelModules = [ "ahci" "xhci_pci" "virtio_pci" "sr_mod" "virtio_blk" ];
boot.initrd.kernelModules = []; boot.initrd.kernelModules = [ ];
boot.kernelModules = []; boot.kernelModules = [ ];
boot.extraModulePackages = []; boot.extraModulePackages = [ ];
fileSystems."/" = { fileSystems."/" = {
device = "/dev/disk/by-label/nixos"; device = "/dev/disk/by-label/nixos";
@ -27,5 +26,5 @@
fsType = "vfat"; fsType = "vfat";
}; };
swapDevices = [{device = "/dev/disk/by-label/swap";}]; swapDevices = [{ device = "/dev/disk/by-label/swap"; }];
} }

View file

@ -1,5 +1,5 @@
{self, ...}: { { self, ... }: {
imports = [./hardware-configuration.nix]; imports = [ ./hardware-configuration.nix ];
eboskma = { eboskma = {
base = { base = {

View file

@ -1,21 +1,20 @@
# Do not modify this file! It was generated by nixos-generate-config # Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes # and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead. # to /etc/nixos/configuration.nix instead.
{ { config
config, , lib
lib, , pkgs
pkgs, , modulesPath
modulesPath, , ...
...
}: { }: {
imports = [ imports = [
(modulesPath + "/profiles/qemu-guest.nix") (modulesPath + "/profiles/qemu-guest.nix")
]; ];
boot.initrd.availableKernelModules = ["ahci" "xhci_pci" "virtio_pci" "sr_mod" "virtio_blk"]; boot.initrd.availableKernelModules = [ "ahci" "xhci_pci" "virtio_pci" "sr_mod" "virtio_blk" ];
boot.initrd.kernelModules = ["kvm-amd"]; boot.initrd.kernelModules = [ "kvm-amd" ];
boot.kernelModules = ["kvm-amd"]; boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = []; boot.extraModulePackages = [ ];
fileSystems."/" = { fileSystems."/" = {
device = "/dev/disk/by-label/nixos"; device = "/dev/disk/by-label/nixos";
@ -27,5 +26,5 @@
fsType = "vfat"; fsType = "vfat";
}; };
swapDevices = [{device = "/dev/disk/by-label/swap";}]; swapDevices = [{ device = "/dev/disk/by-label/swap"; }];
} }

View file

@ -1,18 +1,18 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.backscrub; cfg = config.eboskma.backscrub;
in { in
{
options.eboskma.backscrub = { options.eboskma.backscrub = {
enable = mkEnableOption "enable v4l2loopback kernel module"; enable = mkEnableOption "enable v4l2loopback kernel module";
}; };
config = mkIf (cfg.enable) { config = mkIf (cfg.enable) {
boot.extraModulePackages = [config.boot.kernelPackages.v4l2loopback]; boot.extraModulePackages = [ config.boot.kernelPackages.v4l2loopback ];
# Register a v4l2loopback device at boot # Register a v4l2loopback device at boot
boot.kernelModules = [ boot.kernelModules = [
"v4l2loopback" "v4l2loopback"
@ -25,6 +25,6 @@ in {
options v4l2loopback card_label="VirtualCam" options v4l2loopback card_label="VirtualCam"
''; '';
environment.systemPackages = with pkgs; [backscrub]; environment.systemPackages = with pkgs; [ backscrub ];
}; };
} }

View file

@ -1,8 +1,7 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.base; cfg = config.eboskma.base;
@ -11,7 +10,8 @@ with lib; let
inherit (pkgs.stdenv) mkDerivation; inherit (pkgs.stdenv) mkDerivation;
inherit lib; inherit lib;
}; };
in { in
{
options.eboskma.base = { options.eboskma.base = {
kernel = mkOption { kernel = mkOption {
description = "which kernel to run"; description = "which kernel to run";

View file

@ -1,6 +1,6 @@
{ { mkDerivation
mkDerivation, , lib
lib, ,
}: }:
mkDerivation { mkDerivation {
pname = "probe-rs-udev-rules"; pname = "probe-rs-udev-rules";

View file

@ -1,12 +1,12 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.bluetooth; cfg = config.eboskma.bluetooth;
in { in
{
options.eboskma.bluetooth = { options.eboskma.bluetooth = {
enable = mkEnableOption "activate bluetooth"; enable = mkEnableOption "activate bluetooth";
}; };

View file

@ -1,15 +1,15 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , inputs
inputs, , self-overlay
self-overlay, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.desktop; cfg = config.eboskma.desktop;
bt = config.eboskma.bluetooth; bt = config.eboskma.bluetooth;
in { in
{
# imports = [ ../../users/erwin.nix ../../users/root.nix ]; # imports = [ ../../users/erwin.nix ../../users/root.nix ];
options.eboskma.desktop = { options.eboskma.desktop = {
@ -43,7 +43,7 @@ in {
EDITOR = "${pkgs.neovim}/bin/nvim"; EDITOR = "${pkgs.neovim}/bin/nvim";
}; };
nixpkgs.config = {allowUnfree = true;}; nixpkgs.config = { allowUnfree = true; };
home.stateVersion = "21.11"; home.stateVersion = "21.11";
@ -101,7 +101,7 @@ in {
imagemagick imagemagick
imv imv
iotop iotop
(jetbrains.clion.override {jdk = pkgs.jetbrains.jdk;}) (jetbrains.clion.override { jdk = pkgs.jetbrains.jdk; })
kicad kicad
mpv mpv
nomachine-client nomachine-client
@ -119,7 +119,7 @@ in {
wireshark wireshark
wl-clipboard wl-clipboard
] ]
++ (with gst_all_1; [gstreamer gstreamer.dev gst-plugins-base gst-plugins-good gst-plugins-bad gst-plugins-ugly gst-libav gst-vaapi]); ++ (with gst_all_1; [ gstreamer gstreamer.dev gst-plugins-base gst-plugins-good gst-plugins-bad gst-plugins-ugly gst-libav gst-vaapi ]);
xdg = { xdg = {
enable = true; enable = true;
@ -156,7 +156,7 @@ in {
i18n.inputMethod = { i18n.inputMethod = {
enabled = "fcitx5"; enabled = "fcitx5";
fcitx5.addons = with pkgs; [fcitx5-m17n fcitx5-gtk fcitx5-configtool]; fcitx5.addons = with pkgs; [ fcitx5-m17n fcitx5-gtk fcitx5-configtool ];
}; };
gtk = { gtk = {
@ -246,13 +246,13 @@ in {
portal = { portal = {
enable = true; enable = true;
wlr.enable = true; wlr.enable = true;
extraPortals = with pkgs; [xdg-desktop-portal-gtk]; extraPortals = with pkgs; [ xdg-desktop-portal-gtk ];
gtkUsePortal = true; gtkUsePortal = true;
}; };
}; };
services = { services = {
dbus.packages = [pkgs.gcr]; dbus.packages = [ pkgs.gcr ];
avahi.publish.workstation = true; avahi.publish.workstation = true;
gvfs.enable = true; gvfs.enable = true;
pcscd.enable = true; pcscd.enable = true;
@ -271,7 +271,7 @@ in {
updateWtmp = true; updateWtmp = true;
startSession = true; startSession = true;
}; };
pki.certificates = [(builtins.readFile ./horus-ca.pem)]; pki.certificates = [ (builtins.readFile ./horus-ca.pem) ];
}; };
environment = { environment = {

View file

@ -1,16 +1,16 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.docker; cfg = config.eboskma.docker;
in { in
options.eboskma.docker = {enable = mkEnableOption "activate docker";}; {
options.eboskma.docker = { enable = mkEnableOption "activate docker"; };
config = mkIf cfg.enable { config = mkIf cfg.enable {
environment.systemPackages = with pkgs; [docker-compose]; environment.systemPackages = with pkgs; [ docker-compose ];
virtualisation.docker = { virtualisation.docker = {
enable = true; enable = true;
@ -20,6 +20,6 @@ in {
}; };
}; };
users.extraUsers.${config.eboskma.var.mainUser}.extraGroups = ["docker"]; users.extraUsers.${config.eboskma.var.mainUser}.extraGroups = [ "docker" ];
}; };
} }

View file

@ -1,12 +1,12 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.drone; cfg = config.eboskma.drone;
in { in
{
options.eboskma.drone = { options.eboskma.drone = {
enable = mkEnableOption "activate drone CI"; enable = mkEnableOption "activate drone CI";
}; };
@ -18,8 +18,8 @@ in {
drone = { drone = {
autoStart = true; autoStart = true;
image = "drone/drone:2"; image = "drone/drone:2";
ports = ["8100:80"]; ports = [ "8100:80" ];
volumes = ["drone_data:/data"]; volumes = [ "drone_data:/data" ];
environmentFiles = [ environmentFiles = [
/var/run/secrets/drone /var/run/secrets/drone
]; ];
@ -28,7 +28,7 @@ in {
drone-runner-docker = { drone-runner-docker = {
autoStart = true; autoStart = true;
image = "drone/drone-runner-docker:1"; image = "drone/drone-runner-docker:1";
ports = ["3000:3000"]; ports = [ "3000:3000" ];
volumes = [ volumes = [
"/var/run/docker.sock:/var/run/docker.sock" "/var/run/docker.sock:/var/run/docker.sock"
]; ];

View file

@ -1,14 +1,14 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.element-web; cfg = config.eboskma.element-web;
matrixClientConfig = pkgs.writeText "element-web.json" (builtins.readFile ./element-web.json); matrixClientConfig = pkgs.writeText "element-web.json" (builtins.readFile ./element-web.json);
in { in
options.eboskma.element-web = {enable = mkEnableOption "activate element-web";}; {
options.eboskma.element-web = { enable = mkEnableOption "activate element-web"; };
config = mkIf cfg.enable { config = mkIf cfg.enable {
eboskma.docker.enable = true; eboskma.docker.enable = true;

View file

@ -1,20 +1,20 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.fonts; cfg = config.eboskma.fonts;
in { in
options.eboskma.fonts = {enable = mkEnableOption "activate fonts";}; {
options.eboskma.fonts = { enable = mkEnableOption "activate fonts"; };
config = mkIf cfg.enable { config = mkIf cfg.enable {
fonts = { fonts = {
fontDir.enable = true; fontDir.enable = true;
fonts = with pkgs; [ fonts = with pkgs; [
(nerdfonts.override {fonts = ["CascadiaCode" "DroidSansMono" "FantasqueSansMono" "FiraCode" "Iosevka" "JetBrainsMono" "Meslo" "Noto" "SourceCodePro"];}) (nerdfonts.override { fonts = [ "CascadiaCode" "DroidSansMono" "FantasqueSansMono" "FiraCode" "Iosevka" "JetBrainsMono" "Meslo" "Noto" "SourceCodePro" ]; })
dejavu_fonts dejavu_fonts
google-fonts google-fonts
kochi-substitute kochi-substitute
@ -27,10 +27,10 @@ in {
fontconfig = { fontconfig = {
defaultFonts = { defaultFonts = {
serif = ["Recursive Sans Casual Static Medium"]; serif = [ "Recursive Sans Casual Static Medium" ];
sansSerif = ["Recursive Sans Linear Static Medium"]; sansSerif = [ "Recursive Sans Linear Static Medium" ];
monospace = ["Iosevka Nerd Font"]; monospace = [ "Iosevka Nerd Font" ];
emoji = ["Noto Color Emoji"]; emoji = [ "Noto Color Emoji" ];
}; };
}; };
}; };

View file

@ -1,6 +1,9 @@
{ pkgs, config, lib, ...}: { pkgs
with lib; , config
let , lib
, ...
}:
with lib; let
cfg = config.eboskma.gitea; cfg = config.eboskma.gitea;
giteaCfg = config.services.gitea; giteaCfg = config.services.gitea;
in in
@ -13,19 +16,20 @@ in
user = "git"; user = "git";
domain = "git.datarift.nl"; domain = "git.datarift.nl";
appName = "Gitea Datarift"; appName = "Gitea Datarift";
rootUrl = "https://git.datarift.nl/"; rootUrl = "https://git.datarift.nl/";
log.level = "Warn"; log.level = "Warn";
lfs = { lfs = {
enable = true; enable = true;
}; };
disableRegistration = true; disableRegistration = true;
cookieSecure = true; cookieSecure = true;
database = { database = {
type = "postgres"; type = "postgres";
socket = "/run/postgresql"; socket = "/run/postgresql";
passwordFile = "/run/secrets/gitea_db_password"; passwordFile = "/run/secrets/gitea_db_password";
createDatabase = false; createDatabase = false;
user = "git";
}; };
settings = { settings = {
@ -62,6 +66,8 @@ in
}; };
}; };
networking.firewall.allowedTCPPorts = [ 3000 ];
users.users.git = { users.users.git = {
description = "Gitea service user"; description = "Gitea service user";
home = giteaCfg.stateDir; home = giteaCfg.stateDir;
@ -69,17 +75,17 @@ in
group = "gitea"; group = "gitea";
isSystemUser = true; isSystemUser = true;
}; };
services.postgresql = { services.postgresql = {
enable = true; enable = true;
# Explicitly specify version here, because upgrading is a manual process that involves dumping and restoring databases: # Explicitly specify version here, because upgrading is a manual process that involves dumping and restoring databases:
# https://nixos.org/manual/nixos/unstable/index.html#module-services-postgres-upgrading # https://nixos.org/manual/nixos/unstable/index.html#module-services-postgres-upgrading
package = pkgs.postgresql_14; package = pkgs.postgresql_14;
ensureDatabases = ["gitea"]; ensureDatabases = [ "gitea" ];
ensureUsers = [ ensureUsers = [
{ {
name = "gitea"; name = "git";
ensurePermissions = { ensurePermissions = {
"DATABASE gitea" = "ALL PRIVILEGES"; "DATABASE gitea" = "ALL PRIVILEGES";
}; };

View file

@ -1,12 +1,12 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.gnome; cfg = config.eboskma.gnome;
in { in
{
options.eboskma.gnome.enable = mkEnableOption "activate gnome support settings"; options.eboskma.gnome.enable = mkEnableOption "activate gnome support settings";
config = mkIf (cfg.enable) { config = mkIf (cfg.enable) {

View file

@ -1,69 +1,69 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.greetd; cfg = config.eboskma.greetd;
in { in
{
options.eboskma.greetd = { options.eboskma.greetd = {
enable = mkEnableOption "enable greetd"; enable = mkEnableOption "enable greetd";
}; };
config = config =
mkIf (cfg.enable) mkIf (cfg.enable)
{ {
services.greetd = { services.greetd = {
enable = true; enable = true;
restart = true; restart = true;
settings = { settings = {
default_session = { default_session = {
command = "${pkgs.sway}/bin/sway --config /etc/greetd/sway-config"; command = "${pkgs.sway}/bin/sway --config /etc/greetd/sway-config";
};
}; };
}; };
}; environment.systemPackages = with pkgs; [ greetd.gtkgreet quintom-cursor-theme papirus-icon-theme arc-theme ];
environment.systemPackages = with pkgs; [greetd.gtkgreet quintom-cursor-theme papirus-icon-theme arc-theme];
environment.etc = { environment.etc = {
"greetd/sway-config" = { "greetd/sway-config" = {
text = '' text = ''
# `-l` activates layer-shell mode. Notice that `swaymsg exit` will run after gtkgreet. # `-l` activates layer-shell mode. Notice that `swaymsg exit` will run after gtkgreet.
exec "${pkgs.greetd.gtkgreet}/bin/gtkgreet -l; swaymsg exit" exec "${pkgs.greetd.gtkgreet}/bin/gtkgreet -l; swaymsg exit"
bindsym Mod4+shift+e exec swaynag \ bindsym Mod4+shift+e exec swaynag \
-t warning \ -t warning \
-m 'What do you want to do?' \ -m 'What do you want to do?' \
-b 'Poweroff' 'systemctl poweroff' \ -b 'Poweroff' 'systemctl poweroff' \
-b 'Reboot' 'systemctl reboot' -b 'Reboot' 'systemctl reboot'
include /etc/sway/config.d/* include /etc/sway/config.d/*
''; '';
user = "greeter"; user = "greeter";
group = "greeter"; group = "greeter";
}; };
"greetd/environments" = { "greetd/environments" = {
text = '' text = ''
${pkgs.sway}/bin/sway ${pkgs.sway}/bin/sway
${pkgs.bash}/bin/bash ${pkgs.bash}/bin/bash
''; '';
user = "greeter"; user = "greeter";
group = "greeter"; group = "greeter";
}; };
"sway/config.d/systemd-env.conf" = { "sway/config.d/systemd-env.conf" = {
text = '' text = ''
exec_always --no-startup-id systemctl --user import-environment _JAVA_AWT_WM_NONREPARENTING MOZ_ENABLE_WAYLAND MOZ_DBUS_REMOTE QT_QPA_PLATFORM QT_WAYLAND_DISABLE_WINDOWDECORATION QT_QPA_PLATFORMTHEME SDL_VIDEODRIVER SSH_AUTH_SOCK exec_always --no-startup-id systemctl --user import-environment _JAVA_AWT_WM_NONREPARENTING MOZ_ENABLE_WAYLAND MOZ_DBUS_REMOTE QT_QPA_PLATFORM QT_WAYLAND_DISABLE_WINDOWDECORATION QT_QPA_PLATFORMTHEME SDL_VIDEODRIVER SSH_AUTH_SOCK
exec_always --no-startup-id dbus-update-activation-environment --systemd _JAVA_AWT_WM_NONREPARENTING MOZ_ENABLE_WAYLAND MOZ_DBUS_REMOTE QT_QPA_PLATFORM QT_WAYLAND_DISABLE_WINDOWDECORATION QT_QPA_PLATFORMTHEME SDL_VIDEODRIVER SSH_AUTH_SOCK exec_always --no-startup-id dbus-update-activation-environment --systemd _JAVA_AWT_WM_NONREPARENTING MOZ_ENABLE_WAYLAND MOZ_DBUS_REMOTE QT_QPA_PLATFORM QT_WAYLAND_DISABLE_WINDOWDECORATION QT_QPA_PLATFORMTHEME SDL_VIDEODRIVER SSH_AUTH_SOCK
''; '';
}; };
"xdg/gtk-3.0/settings.ini" = { "xdg/gtk-3.0/settings.ini" = {
text = generators.toINI {} { text = generators.toINI { } {
Settings = { Settings = {
gtk-theme-name = "Arc-Dark"; gtk-theme-name = "Arc-Dark";
gtk-icon-theme-name = "Papirus-Dark"; gtk-icon-theme-name = "Papirus-Dark";
gtk-cursor-theme-name = "Quintom_Ink"; gtk-cursor-theme-name = "Quintom_Ink";
gtk-application-prefer-dark-theme = "true"; gtk-application-prefer-dark-theme = "true";
};
}; };
}; };
}; };
}; };
};
} }

View file

@ -1,12 +1,12 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.livebook; cfg = config.eboskma.livebook;
in { in
{
options.eboskma.livebook = { options.eboskma.livebook = {
enable = mkEnableOption "Start a livebook container"; enable = mkEnableOption "Start a livebook container";
dataDir = mkOption { dataDir = mkOption {

View file

@ -1,12 +1,12 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.networking; cfg = config.eboskma.networking;
in { in
{
options.eboskma.networking = { options.eboskma.networking = {
enable = mkEnableOption "activate networing settings"; enable = mkEnableOption "activate networing settings";
@ -27,13 +27,13 @@ in {
interfaces = listToAttrs (builtins.map interfaces = listToAttrs (builtins.map
(iface: { (iface: {
name = iface; name = iface;
value = {useDHCP = true;}; value = { useDHCP = true; };
}) })
cfg.dhcpInterfaces); cfg.dhcpInterfaces);
hosts = cfg.hosts; hosts = cfg.hosts;
firewall = { firewall = {
trustedInterfaces = ["lo"]; trustedInterfaces = [ "lo" ];
interfaces = listToAttrs (builtins.map interfaces = listToAttrs (builtins.map
(iface: { (iface: {
name = iface; name = iface;
@ -49,7 +49,7 @@ in {
cfg.dhcpInterfaces); cfg.dhcpInterfaces);
}; };
}; };
users.extraUsers.${config.eboskma.var.mainUser}.extraGroups = ["networkmanager"]; users.extraUsers.${config.eboskma.var.mainUser}.extraGroups = [ "networkmanager" ];
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
nmap nmap

View file

@ -1,13 +1,13 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.nginx-proxy-manager; cfg = config.eboskma.nginx-proxy-manager;
in { in
options.eboskma.nginx-proxy-manager = {enable = mkEnableOption "Nginx Proxy Manager";}; {
options.eboskma.nginx-proxy-manager = { enable = mkEnableOption "Nginx Proxy Manager"; };
config = mkIf (cfg.enable) { config = mkIf (cfg.enable) {
eboskma.docker.enable = true; eboskma.docker.enable = true;

View file

@ -1,12 +1,12 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.nix-common; cfg = config.eboskma.nix-common;
in { in
{
options.eboskma.nix-common = { options.eboskma.nix-common = {
enable = mkEnableOption "activate nix-common"; enable = mkEnableOption "activate nix-common";
disable-cache = mkEnableOption "no not use binary cache"; disable-cache = mkEnableOption "no not use binary cache";
@ -25,7 +25,7 @@ in {
settings = { settings = {
auto-optimise-store = true; auto-optimise-store = true;
allowed-users = ["root"]; allowed-users = [ "root" ];
substituters = [ substituters = [
"https://nix-community.cachix.org" "https://nix-community.cachix.org"
]; ];

View file

@ -1,12 +1,12 @@
{ { lib
lib, , pkgs
pkgs, , config
config, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.var; cfg = config.eboskma.var;
in { in
{
options.eboskma.var.mainUser = lib.mkOption { options.eboskma.var.mainUser = lib.mkOption {
type = lib.types.str; type = lib.types.str;
default = "erwin"; default = "erwin";

View file

@ -1,12 +1,12 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.sound; cfg = config.eboskma.sound;
in { in
{
options.eboskma.sound.enable = mkEnableOption "activate sound settings"; options.eboskma.sound.enable = mkEnableOption "activate sound settings";
config = mkIf (cfg.enable) { config = mkIf (cfg.enable) {
@ -21,10 +21,10 @@ in {
config = { config = {
bluez-monitor.rules = [ bluez-monitor.rules = [
{ {
matches = [{"device.name" = "~bluez_card.*";}]; matches = [{ "device.name" = "~bluez_card.*"; }];
actions = { actions = {
"update-props" = { "update-props" = {
"bluez5.reconnect-profiles" = ["hfp_hf" "hsp_hs" "a2dp_sink"]; "bluez5.reconnect-profiles" = [ "hfp_hf" "hsp_hs" "a2dp_sink" ];
"bluez5.msbc-support" = true; "bluez5.msbc-support" = true;
"bluez5.sbc-xq-support" = true; "bluez5.sbc-xq-support" = true;
}; };
@ -32,8 +32,8 @@ in {
} }
{ {
matches = [ matches = [
{"node.name" = "~bluez_input.*";} { "node.name" = "~bluez_input.*"; }
{"node.name" = "~bluez_output.*";} { "node.name" = "~bluez_output.*"; }
]; ];
actions = { actions = {
"node.pause-on-idle" = false; "node.pause-on-idle" = false;
@ -64,8 +64,8 @@ in {
security.rtkit.enable = true; security.rtkit.enable = true;
environment.systemPackages = with pkgs; [pavucontrol]; environment.systemPackages = with pkgs; [ pavucontrol ];
users.extraUsers.${config.eboskma.var.mainUser}.extraGroups = ["audio"]; users.extraUsers.${config.eboskma.var.mainUser}.extraGroups = [ "audio" ];
}; };
} }

View file

@ -1,12 +1,12 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.systemd; cfg = config.eboskma.systemd;
in { in
{
options.eboskma.systemd = { options.eboskma.systemd = {
enable = mkEnableOption "activate systemd settings"; enable = mkEnableOption "activate systemd settings";
}; };

View file

@ -1,14 +1,14 @@
final: prev: rec { final: prev: rec {
rofi-wayland = prev.pkgs.callPackage ../pkgs/rofi-wayland {}; rofi-wayland = prev.pkgs.callPackage ../pkgs/rofi-wayland { };
nix-plugins = prev.pkgs.callPackage ../pkgs/nix-plugins {}; nix-plugins = prev.pkgs.callPackage ../pkgs/nix-plugins { };
lunarvim = prev.pkgs.callPackage ../pkgs/lunarvim {}; lunarvim = prev.pkgs.callPackage ../pkgs/lunarvim { };
backscrub = backscrub =
prev.pkgs.callPackage ../pkgs/backscrub prev.pkgs.callPackage ../pkgs/backscrub
{ {
inherit (prev.pkgs) gcc cmake opencv curl stdenv git tensorflow-lite flatbuffers; inherit (prev.pkgs) gcc cmake opencv curl stdenv git tensorflow-lite flatbuffers;
}; };
onnx-runtime = prev.pkgs.callPackage ../pkgs/onnx-runtime {inherit (prev.pkgs) stdenv;}; onnx-runtime = prev.pkgs.callPackage ../pkgs/onnx-runtime { inherit (prev.pkgs) stdenv; };
obs-backgroundremoval = prev.pkgs.callPackage ../pkgs/obs-backgroundremoval {inherit (prev.pkgs) stdenv fetchFromGitHub cmake obs-studio opencv onnx-runtime;}; obs-backgroundremoval = prev.pkgs.callPackage ../pkgs/obs-backgroundremoval { inherit (prev.pkgs) stdenv fetchFromGitHub cmake obs-studio opencv onnx-runtime; };
swaynotificationcenter = prev.swaynotificationcenter.overrideAttrs (oldAttrs: rec { swaynotificationcenter = prev.swaynotificationcenter.overrideAttrs (oldAttrs: rec {
version = "0.5"; version = "0.5";
@ -19,6 +19,6 @@ final: prev: rec {
hash = "sha256-Jjbr6GJ0MHlO+T/simPNYQnB5b7Cr85j4GRjRGa5B6s="; hash = "sha256-Jjbr6GJ0MHlO+T/simPNYQnB5b7Cr85j4GRjRGa5B6s=";
}; };
nativeBuildInputs = oldAttrs.nativeBuildInputs ++ [prev.scdoc]; nativeBuildInputs = oldAttrs.nativeBuildInputs ++ [ prev.scdoc ];
}); });
} }

View file

@ -1,13 +1,13 @@
{ { stdenv
stdenv, , fetchFromGitHub
fetchFromGitHub, , cmake
cmake, , opencv
opencv, , gcc
gcc, , curl
curl, , git
git, , tensorflow-lite
tensorflow-lite, , flatbuffers
flatbuffers, ,
}: }:
stdenv.mkDerivation { stdenv.mkDerivation {
name = "backscrub"; name = "backscrub";
@ -21,7 +21,7 @@ stdenv.mkDerivation {
sha256 = "14gd77m7dy0wg15y0i8zhki8cm7np2spx7yi162b2xqaav04b1cj"; sha256 = "14gd77m7dy0wg15y0i8zhki8cm7np2spx7yi162b2xqaav04b1cj";
}; };
nativeBuildInputs = [gcc cmake git]; nativeBuildInputs = [ gcc cmake git ];
buildInputs = [opencv curl tensorflow-lite flatbuffers]; buildInputs = [ opencv curl tensorflow-lite flatbuffers ];
patches = [./fix-cmake-for-nixos.patch]; patches = [ ./fix-cmake-for-nixos.patch ];
} }

View file

@ -1,36 +1,36 @@
{pkgs, ...}: { pkgs, ... }:
with pkgs; let with pkgs; let
nvim-customized = wrapNeovim neovim-unwrapped {}; nvim-customized = wrapNeovim neovim-unwrapped { };
in in
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
pname = "lunarvim"; pname = "lunarvim";
version = "0.0.1"; version = "0.0.1";
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "LunarVim"; owner = "LunarVim";
repo = "LunarVim"; repo = "LunarVim";
rev = "0e531891b1dfd04fa02a22b48ce075120b512277"; rev = "0e531891b1dfd04fa02a22b48ce075120b512277";
sha256 = "0yfr3vh8p1s9wy21s6bgpp6kp6s9pqlb6k66s76sa22vz4sjiyxb"; sha256 = "0yfr3vh8p1s9wy21s6bgpp6kp6s9pqlb6k66s76sa22vz4sjiyxb";
}; };
nativeBuildInputs = [makeWrapper nvim-customized]; nativeBuildInputs = [ makeWrapper nvim-customized ];
buildInputs = [nvim-customized]; buildInputs = [ nvim-customized ];
buildPhase = '' buildPhase = ''
echo "hello" echo "hello"
''; '';
installPhase = '' installPhase = ''
runHook preInstall runHook preInstall
mkdir -p $out/bin mkdir -p $out/bin
cp -r $(pwd) $out/lvim cp -r $(pwd) $out/lvim
export shim="$out/lvim/utils/bin/lvim" export shim="$out/lvim/utils/bin/lvim"
substituteInPlace "$shim" \ substituteInPlace "$shim" \
--replace "exec nvim" "exec ${nvim-customized}/bin/nvim" --replace "exec nvim" "exec ${nvim-customized}/bin/nvim"
chmod +x "$shim" chmod +x "$shim"
makeWrapper "$shim" "$out/bin/lvim" \ makeWrapper "$shim" "$out/bin/lvim" \
--set LUNARVIM_RUNTIME_DIR "$out" \ --set LUNARVIM_RUNTIME_DIR "$out" \
--prefix PATH : ${lib.makeBinPath [fzf git ripgrep]} --prefix PATH : ${lib.makeBinPath [fzf git ripgrep]}
runHook postInstall runHook postInstall
''; '';
} }

View file

@ -1,12 +1,12 @@
{ { lib
lib, , stdenv
stdenv, , fetchFromGitHub
fetchFromGitHub, , nixUnstable
nixUnstable, , cmake
cmake, , pkg-config
pkg-config, , boost
boost, , nlohmann_json
nlohmann_json, ,
}: }:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
pname = "nix-plugins"; pname = "nix-plugins";
@ -19,9 +19,9 @@ stdenv.mkDerivation rec {
sha256 = "sha256-Zbc0iq5ZAr73B+NJvpBHm9GIJhb9qrq0vFmV/ucNT5I="; sha256 = "sha256-Zbc0iq5ZAr73B+NJvpBHm9GIJhb9qrq0vFmV/ucNT5I=";
}; };
nativeBuildInputs = [cmake pkg-config]; nativeBuildInputs = [ cmake pkg-config ];
buildInputs = [nixUnstable boost nlohmann_json]; buildInputs = [ nixUnstable boost nlohmann_json ];
meta = { meta = {
description = "Collection of miscellaneous plugins for the nix expression language"; description = "Collection of miscellaneous plugins for the nix expression language";

View file

@ -1,11 +1,11 @@
{ { fetchFromGitHub
fetchFromGitHub, , stdenv
stdenv, , cmake
cmake, , obs-studio
obs-studio, , opencv
opencv, , onnx-runtime
onnx-runtime, , git
git, ,
}: }:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
pname = "obs-backgroundremoval"; pname = "obs-backgroundremoval";
@ -18,9 +18,9 @@ stdenv.mkDerivation rec {
sha256 = "TI1FlhE0+JL50gAZCSsI+g8savX8GRQkH3jYli/66hQ="; sha256 = "TI1FlhE0+JL50gAZCSsI+g8savX8GRQkH3jYli/66hQ=";
}; };
cmakeFlags = ["-DGIT_TAG=v${version}"]; cmakeFlags = [ "-DGIT_TAG=v${version}" ];
patches = [./cmake_set_version.patch]; patches = [ ./cmake_set_version.patch ];
nativeBuildInputs = [cmake git]; nativeBuildInputs = [ cmake git ];
buildInputs = [opencv onnx-runtime obs-studio]; buildInputs = [ opencv onnx-runtime obs-studio ];
} }

View file

@ -1,4 +1,4 @@
{stdenv}: { stdenv }:
stdenv.mkDerivation { stdenv.mkDerivation {
pname = "onnx-runtime"; pname = "onnx-runtime";
version = "1.7.0"; version = "1.7.0";

View file

@ -1,52 +1,52 @@
{pkgs, ...}: { pkgs, ... }:
with pkgs; with pkgs;
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
pname = "rofi-wayland-unwrapped"; pname = "rofi-wayland-unwrapped";
version = "1.7.3"; version = "1.7.3";
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "lbonn"; owner = "lbonn";
repo = "rofi"; repo = "rofi";
rev = "${version}+wayland1"; rev = "${version}+wayland1";
fetchSubmodules = true; fetchSubmodules = true;
# sha256 = "1h6lh4lrkxzs6iy2rzn5g71dnz6qck4j8cxpgy1ja179vrnj1sf7"; # sha256 = "1h6lh4lrkxzs6iy2rzn5g71dnz6qck4j8cxpgy1ja179vrnj1sf7";
sha256 = "qvIxWxiQj42VgScSsrF1Yf6ifgEbZes0flNbbwc3O8I="; sha256 = "qvIxWxiQj42VgScSsrF1Yf6ifgEbZes0flNbbwc3O8I=";
}; };
preConfigure = '' preConfigure = ''
patchShebangs "script" patchShebangs "script"
# root not present in build /etc/passwd # root not present in build /etc/passwd
sed -i 's/~root/~nobody/g' test/helper-expand.c sed -i 's/~root/~nobody/g' test/helper-expand.c
''; '';
nativeBuildInputs = [meson ninja pkgconfig]; nativeBuildInputs = [ meson ninja pkgconfig ];
buildInputs = with pkgs; [ buildInputs = with pkgs; [
libxkbcommon libxkbcommon
pango pango
cairo cairo
git git
bison bison
flex flex
librsvg librsvg
check check
libstartup_notification libstartup_notification
xorg.libxcb xorg.libxcb
xorg.xcbutil xorg.xcbutil
xorg.xcbutilwm xorg.xcbutilwm
xcb-util-cursor xcb-util-cursor
xcbutilxrm xcbutilxrm
which which
wayland-protocols wayland-protocols
wayland wayland
]; ];
doCheck = false; doCheck = false;
meta = with lib; { meta = with lib; {
description = "Window switcher, run dialog and dmenu replacement"; description = "Window switcher, run dialog and dmenu replacement";
homepage = "https://github.com/davatorium/rofi"; homepage = "https://github.com/davatorium/rofi";
license = licenses.mit; license = licenses.mit;
maintainers = with maintainers; [c0deaddict]; maintainers = with maintainers; [ c0deaddict ];
platforms = with platforms; linux; platforms = with platforms; linux;
}; };
} }

View file

@ -1,8 +1,8 @@
{pkgs, ...}: { { pkgs, ... }: {
users.users.erwin = { users.users.erwin = {
isNormalUser = true; isNormalUser = true;
home = "/home/erwin"; home = "/home/erwin";
extraGroups = ["wheel" "adm" "audio" "video"]; extraGroups = [ "wheel" "adm" "audio" "video" ];
shell = pkgs.fish; shell = pkgs.fish;
openssh.authorizedKeys.keyFiles = [ openssh.authorizedKeys.keyFiles = [
(pkgs.fetchurl { (pkgs.fetchurl {
@ -12,5 +12,5 @@
]; ];
}; };
nix.settings.allowed-users = ["erwin"]; nix.settings.allowed-users = [ "erwin" ];
} }

View file

@ -1,15 +1,14 @@
{ { pkgs
pkgs, , config
config, , lib
lib, , ...
...
}: }:
with lib; let with lib; let
cfg = config.eboskma.desktop; cfg = config.eboskma.desktop;
in { in
options.eboskma.desktop = {enable = mkEnableOption "desktop configuration";}; {
options.eboskma.desktop = { enable = mkEnableOption "desktop configuration"; };
config = config =
mkIf (cfg.enable) { mkIf (cfg.enable) { };
};
} }

View file

@ -1,4 +1,4 @@
{pkgs, ...}: { { pkgs, ... }: {
users.users.root = { users.users.root = {
openssh.authorizedKeys.keyFiles = [ openssh.authorizedKeys.keyFiles = [
(pkgs.fetchurl { (pkgs.fetchurl {