Compare commits

..

No commits in common. "6441dc9cf1b4c58fa4d66b6c09af27d2d1a06d47" and "bb6d87e9dc809b1a229be16fb97b33d245f08d8e" have entirely different histories.

18 changed files with 387 additions and 298 deletions

View file

@ -31,11 +31,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1709610799, "lastModified": 1701025348,
"narHash": "sha256-5jfLQx0U9hXbi2skYMGodDJkIgffrjIOgMRjZqms2QE=", "narHash": "sha256-42GHmYH+GF7VjwGSt+fVT1CQuNpGanJbNgVHTAZppUM=",
"owner": "ipetkov", "owner": "ipetkov",
"repo": "crane", "repo": "crane",
"rev": "81c393c776d5379c030607866afef6406ca1be57", "rev": "42afaeb1a0325194a7cdb526332d2cb92fddd07b",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -52,11 +52,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1710073490, "lastModified": 1703245373,
"narHash": "sha256-4B3McqiXy8TaNp8G134BQMx+m/A/VidMYRGcD4bda0k=", "narHash": "sha256-diJVcEb5RzMQqrXl2hXUUY1SvSSJEg4ttpzij6skyew=",
"owner": "michaelshmitty", "owner": "michaelshmitty",
"repo": "cryptpad-flake", "repo": "cryptpad-flake",
"rev": "6657541cfcd18ca328c8d3a41b9bf18bc5f10099", "rev": "369a95c89e1448a1bc26ad8d0e57618fc0a5dc90",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -72,11 +72,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1710281379, "lastModified": 1708737761,
"narHash": "sha256-uFo9hxt982L3nFJeweW4Gip2esiGrIQlbvEGrNTh4AY=", "narHash": "sha256-sR/1cYjpgr71ZSrt6Kp5Dg4Ul3mo6pZIG400tuzYks8=",
"owner": "lnl7", "owner": "lnl7",
"repo": "nix-darwin", "repo": "nix-darwin",
"rev": "d9ea313bc4851670dc99c5cc979cb79750e7d670", "rev": "bbde06bed1b72eddff063fa42f18644e90a0121e",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -93,11 +93,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1710427903, "lastModified": 1708564520,
"narHash": "sha256-sV0Q5ndvfjK9JfCg/QM/HX/fcittohvtq8dD62isxdM=", "narHash": "sha256-juduDTYBhGN6jNfQ5RMDpbQF+MkO0pj3k7XGDSTjAbs=",
"owner": "nix-community", "owner": "nix-community",
"repo": "disko", "repo": "disko",
"rev": "21d89b333ca300bef82c928c856d48b94a9f997c", "rev": "23d308f0059955e3719efc81a34d1fc0369fbb74",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -183,11 +183,11 @@
"systems": "systems_2" "systems": "systems_2"
}, },
"locked": { "locked": {
"lastModified": 1710146030, "lastModified": 1705309234,
"narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", "narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=",
"owner": "numtide", "owner": "numtide",
"repo": "flake-utils", "repo": "flake-utils",
"rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", "rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -225,11 +225,11 @@
"rust-overlay": "rust-overlay" "rust-overlay": "rust-overlay"
}, },
"locked": { "locked": {
"lastModified": 1710393236, "lastModified": 1708745305,
"narHash": "sha256-3XUAUU170gvD8FZ5VnAYKzYLeC6PQHG2aBVW2d4BmHk=", "narHash": "sha256-AxBvMahNT310JVOSLT8MFjUXhpPzDXaSxNluNTod36A=",
"owner": "helix-editor", "owner": "helix-editor",
"repo": "helix", "repo": "helix",
"rev": "6c4d986c1b1ac4e350dced513b6608ba4464cde3", "rev": "ec9efdef3b2f613a86098058f5705e7863e375e2",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -242,20 +242,20 @@
"home-manager": { "home-manager": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
"nixpkgs-nixos-unstable" "nixpkgs-stable"
] ]
}, },
"locked": { "locked": {
"lastModified": 1710532761, "lastModified": 1706981411,
"narHash": "sha256-SUXGZNrXX05YA9G6EmgupxhOr3swI1gcxLUeDMUhrEY=", "narHash": "sha256-cLbLPTL1CDmETVh4p0nQtvoF+FSEjsnJTFpTxhXywhQ=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "206f457fffdb9a73596a4cb2211a471bd305243d", "rev": "652fda4ca6dafeb090943422c34ae9145787af37",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "nix-community", "owner": "nix-community",
"ref": "master", "ref": "release-23.11",
"repo": "home-manager", "repo": "home-manager",
"type": "github" "type": "github"
} }
@ -308,11 +308,11 @@
}, },
"nixos-hardware": { "nixos-hardware": {
"locked": { "locked": {
"lastModified": 1710123225, "lastModified": 1708594753,
"narHash": "sha256-j3oWlxRZxB7cFsgEntpH3rosjFHRkAo/dhX9H3OfxtY=", "narHash": "sha256-c/gH7iXS/IYH9NrFOT+aJqTq+iEBkvAkpWuUHGU3+f0=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixos-hardware", "repo": "nixos-hardware",
"rev": "ad2fd7b978d5e462048729a6c635c45d3d33c9ba", "rev": "3f7d0bca003eac1a1a7f4659bbab9c8f8c2a0958",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -324,11 +324,11 @@
}, },
"nixpkgs-master": { "nixpkgs-master": {
"locked": { "locked": {
"lastModified": 1710494698, "lastModified": 1708770680,
"narHash": "sha256-oMilsMpnRFzG7kpoWLoZePt4lttZGkN36OAf8DGnE00=", "narHash": "sha256-uS1Jji64SPBKu5/VdNYj3volc/xAmDgsBguq4zgBWDw=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "453b69da7a400af2c669793ee504b016b3fd3639", "rev": "d01044ecfa9c89a925bebb76cf60f2e3b9cea667",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -340,11 +340,11 @@
}, },
"nixpkgs-nixos-unstable": { "nixpkgs-nixos-unstable": {
"locked": { "locked": {
"lastModified": 1710272261, "lastModified": 1708655239,
"narHash": "sha256-g0bDwXFmTE7uGDOs9HcJsfLFhH7fOsASbAuOzDC+fhQ=", "narHash": "sha256-ZrP/yACUvDB+zbqYJsln4iwotbH6CTZiTkANJ0AgDv4=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "0ad13a6833440b8e238947e47bea7f11071dc2b2", "rev": "cbc4211f0afffe6dfd2478a62615dd5175a13f9a",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -356,11 +356,11 @@
}, },
"nixpkgs-rust-analyzer": { "nixpkgs-rust-analyzer": {
"locked": { "locked": {
"lastModified": 1710494698, "lastModified": 1708770680,
"narHash": "sha256-oMilsMpnRFzG7kpoWLoZePt4lttZGkN36OAf8DGnE00=", "narHash": "sha256-uS1Jji64SPBKu5/VdNYj3volc/xAmDgsBguq4zgBWDw=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "453b69da7a400af2c669793ee504b016b3fd3639", "rev": "d01044ecfa9c89a925bebb76cf60f2e3b9cea667",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -372,11 +372,11 @@
}, },
"nixpkgs-stable": { "nixpkgs-stable": {
"locked": { "locked": {
"lastModified": 1710420202, "lastModified": 1708566995,
"narHash": "sha256-MvFKESbq4rUWuaf2RKPNYENaSZEw/jaCLo2gU6oREcM=", "narHash": "sha256-e/THimsoxxMAHSbwMKov5f5Yg+utTj6XVGEo24Lhx+0=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "878ef7d9721bee9f81f8a80819f9211ad1f993da", "rev": "3cb4ae6689d2aa3f363516234572613b31212b78",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -388,11 +388,11 @@
}, },
"nur": { "nur": {
"locked": { "locked": {
"lastModified": 1710494722, "lastModified": 1708771490,
"narHash": "sha256-rjYCRxjuNJYH8/YJ3G3fQsdq17pVIdyH5yMSNDQznBg=", "narHash": "sha256-HYFlXYMWDHZmwazXGNu0DT5M/ZNkYTOMtUxh40onEGA=",
"owner": "nix-community", "owner": "nix-community",
"repo": "NUR", "repo": "NUR",
"rev": "e1d526df83b9ef104150b67d89afb4d4c20975d7", "rev": "7f0cad37958f31e19255fcc50683c638caa3149e",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -454,11 +454,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1709604635, "lastModified": 1701137803,
"narHash": "sha256-le4fwmWmjGRYWwkho0Gr7mnnZndOOe4XGbLw68OvF40=", "narHash": "sha256-0LcPAdql5IhQSUXJx3Zna0dYTgdIoYO7zUrsKgiBd04=",
"owner": "oxalica", "owner": "oxalica",
"repo": "rust-overlay", "repo": "rust-overlay",
"rev": "e86c0fb5d3a22a5f30d7f64ecad88643fe26449d", "rev": "9dd940c967502f844eacea52a61e9596268d4f70",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -502,11 +502,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1710433464, "lastModified": 1708500294,
"narHash": "sha256-IXlPoWgIRovZ32mYvqqdBgOQln71LouE/HBhbKc1wcw=", "narHash": "sha256-mvJIecY3tDKZh7297mqOtOuAvP7U1rqjfLNfmfkjFpU=",
"owner": "Mic92", "owner": "Mic92",
"repo": "sops-nix", "repo": "sops-nix",
"rev": "6c32d3b9c7593f4b466ec5404e59fc09a803a090", "rev": "f6b80ab6cd25e57f297fe466ad689d8a77057c11",
"type": "github" "type": "github"
}, },
"original": { "original": {

View file

@ -159,7 +159,7 @@
}; };
nixosConfigurations = { nixosConfigurations = {
foryog = mkWorkstation nixpkgs-nixos-unstable "x86_64-linux" "foryog"; foryog = mkWorkstation nixpkgs-stable "x86_64-linux" "foryog";
thinky = mkWorkstation nixpkgs-stable "x86_64-linux" "thinky"; thinky = mkWorkstation nixpkgs-stable "x86_64-linux" "thinky";
bolty = mkServer nixpkgs-stable "x86_64-linux" "bolty"; bolty = mkServer nixpkgs-stable "x86_64-linux" "bolty";
vpsfree1 = mkServer nixpkgs-stable "x86_64-linux" "vpsfree1"; vpsfree1 = mkServer nixpkgs-stable "x86_64-linux" "vpsfree1";
@ -274,8 +274,8 @@
type = "github"; type = "github";
owner = "nix-community"; owner = "nix-community";
repo = "home-manager"; repo = "home-manager";
ref = "master"; ref = "release-23.11";
inputs.nixpkgs.follows = "nixpkgs-nixos-unstable"; inputs.nixpkgs.follows = "nixpkgs-stable";
}; };
flake-utils = { flake-utils = {
type = "github"; type = "github";

View file

@ -15,6 +15,7 @@
]; ];
timerConfig = {OnCalendar = "daily";}; timerConfig = {OnCalendar = "daily";};
pruneOpts = [ pruneOpts = [
"--keep-hourly 25"
"--keep-daily 8" "--keep-daily 8"
"--keep-weekly 5" "--keep-weekly 5"
"--keep-monthly 13" "--keep-monthly 13"

View file

@ -1,4 +1,10 @@
{ config, pkgs, inputs, lib, ... }: { {
config,
pkgs,
inputs,
lib,
...
}: {
imports = [ imports = [
"${inputs.nixpkgs-stable}/nixos/modules/profiles/qemu-guest.nix" "${inputs.nixpkgs-stable}/nixos/modules/profiles/qemu-guest.nix"
../cli.nix ../cli.nix
@ -7,7 +13,7 @@
./cryptpad.nix ./cryptpad.nix
./disks.nix ./disks.nix
./foundryvtt.nix ./foundryvtt.nix
./forgejo.nix ./gitea.nix
./mastodon.nix ./mastodon.nix
./rss.nix ./rss.nix
./ssh.nix ./ssh.nix

View file

@ -1,103 +0,0 @@
{ config, pkgs, inputs, lib, system, ... }:
let
unstable = inputs.nixpkgs-nixos-unstable;
package = unstable.legacyPackages."${system}".forgejo;
httpPort = 8083;
sshPort = 22;
domain = "git.cyplo.dev";
emailDomain = "peninsula.industries";
baseurl = "https://${domain}";
mailgunSmtpSecretName = "forgejo-mailgun-smtp-password";
mailgunSmtpPasswordPath = "/run/secrets/${mailgunSmtpSecretName}";
uid = 2051;
gid = 3051;
systemUserName = "forgejo";
systemGroupName = "forgejo";
users = {
users."${systemUserName}" = {
inherit uid;
isSystemUser = true;
isNormalUser = false;
group = systemGroupName;
};
groups."${systemGroupName}" = {
inherit gid;
members = [ "${systemUserName}" "nginx" ];
};
};
in {
imports =
[ ../nginx.nix "${unstable}/nixos/modules/services/misc/forgejo.nix" ];
disabledModules = [ "services/misc/forgejo.nix" ];
inherit users;
boot.kernel.sysctl = { "net.ipv4.ip_unprivileged_port_start" = 0; };
systemd.services.systemd-sysctl.enable = lib.mkForce true;
networking.firewall.allowedTCPPorts = [ sshPort ];
services.nginx = {
virtualHosts = {
"${domain}" = {
forceSSL = true;
enableACME = true;
locations."/" = {
proxyPass = "http://127.0.0.1:" + toString httpPort;
};
};
};
};
sops.secrets."${mailgunSmtpSecretName}" = {
sopsFile = ./mailgun.sops.yaml;
path = mailgunSmtpPasswordPath;
owner = systemUserName;
group = systemGroupName;
};
services.forgejo = {
enable = true;
inherit package;
user = systemUserName;
mailerPasswordFile = mailgunSmtpPasswordPath;
lfs.enable = true;
database.type = "sqlite3";
settings = {
service.DISABLE_REGISTRATION = true;
security.INSTALL_LOCK = true;
oauth2.ENABLE = false;
log.LEVEL = "Info";
actions.ENABLED = true;
"git.timeout" = {
DEFAULT = 600;
MIGRATE = 3600;
MIRROR = 3600;
CLONE = 600;
PULL = 600;
GC = 600;
};
"cron".ENABLED = true;
"cron.git_gc_repos".ENABLED = true;
"cron.delete_old_actions".ENABLED = true;
"cron.delete_old_system_notices".ENABLED = true;
"cron.gc_lfs".ENABLED = true;
server = {
ROOT_URL = baseurl;
DOMAIN = domain;
START_SSH_SERVER = true;
SSH_PORT = sshPort;
HTTP_PORT = httpPort;
SSH_LISTEN_PORT = sshPort;
DISABLE_SSH = false;
};
mailer = {
ENABLED = true;
FROM = "git.cyplo.dev <forgejo@${emailDomain}>";
PROTOCOL = "smtps";
SMTP_ADDR = "smtp.eu.mailgun.org";
SMTP_PORT = 465;
USER = "postmaster@${emailDomain}";
};
};
};
}

View file

@ -0,0 +1,148 @@
{
config,
pkgs,
inputs,
lib,
system,
...
}: let
unstable = inputs.nixpkgs-nixos-unstable;
package = unstable.legacyPackages."${system}".forgejo;
httpPort = 8083;
sshPort = 22;
domain = "git.cyplo.dev";
emailDomain = "peninsula.industries";
baseurl = "https://${domain}";
path = "/var/lib/gitea";
mailgunSmtpSecretName = "gitea-mailgun-smtp-password";
mailgunSmtpPasswordPath = "/run/secrets/${mailgunSmtpSecretName}";
uid = 2051;
gid = 3051;
systemUserName = "gitea";
systemGroupName = "gitea";
users = {
users."${systemUserName}" = {
inherit uid;
isSystemUser = true;
isNormalUser = false;
group = systemGroupName;
};
groups."${systemGroupName}" = {
inherit gid;
members = ["${systemUserName}" "nginx"];
};
};
in {
imports = [../nginx.nix];
inherit users;
boot.kernel.sysctl = {"net.ipv4.ip_unprivileged_port_start" = 0;};
systemd.services.systemd-sysctl.enable = lib.mkForce true;
networking.firewall.allowedTCPPorts = [sshPort];
services.nginx = {
virtualHosts = {
"${domain}" = {
forceSSL = true;
enableACME = true;
locations."/" = {
proxyPass = "http://127.0.0.1:" + toString httpPort;
};
};
};
};
sops.secrets."${mailgunSmtpSecretName}" = {
sopsFile = ./mailgun.sops.yaml;
path = mailgunSmtpPasswordPath;
owner = systemUserName;
group = systemGroupName;
};
containers.gitea = {
autoStart = true;
forwardPorts = [
{
inherit httpPort;
containerPort = httpPort;
}
{
containerPort = sshPort;
hostPort = sshPort;
}
];
bindMounts = {
"${path}" = {
hostPath = "${path}";
isReadOnly = false;
};
"${mailgunSmtpPasswordPath}" = {
hostPath = "${mailgunSmtpPasswordPath}";
isReadOnly = true;
};
};
config = {
config,
pkgs,
lib,
...
}: {
system.stateVersion = "23.11";
users =
users
// {
mutableUsers = false;
allowNoPasswordLogin = true;
};
disabledModules = ["services/misc/gitea.nix"];
imports = ["${unstable}/nixos/modules/services/misc/gitea.nix"];
services.gitea = {
enable = true;
inherit package;
stateDir = path;
user = systemUserName;
mailerPasswordFile = mailgunSmtpPasswordPath;
lfs.enable = true;
database.type = "sqlite3";
settings = {
service.DISABLE_REGISTRATION = true;
security.INSTALL_LOCK = true;
oauth2.ENABLE = false;
log.LEVEL = "Info";
actions.ENABLED = true;
"git.timeout" = {
DEFAULT = 600;
MIGRATE = 3600;
MIRROR = 3600;
CLONE = 600;
PULL = 600;
GC = 600;
};
"cron".ENABLED = true;
"cron.git_gc_repos".ENABLED = true;
"cron.delete_old_actions".ENABLED = true;
"cron.delete_old_system_notices".ENABLED = true;
"cron.gc_lfs".ENABLED = true;
server = {
ROOT_URL = baseurl;
DOMAIN = domain;
START_SSH_SERVER = true;
SSH_PORT = sshPort;
HTTP_PORT = httpPort;
SSH_LISTEN_PORT = sshPort;
DISABLE_SSH = false;
};
mailer = {
ENABLED = true;
FROM = "git.cyplo.dev <gitea@${emailDomain}>";
PROTOCOL = "smtps";
SMTP_ADDR = "smtp.eu.mailgun.org";
SMTP_PORT = 465;
USER = "postmaster@${emailDomain}";
};
};
};
};
};
}

View file

@ -1,4 +1,4 @@
forgejo-mailgun-smtp-password: ENC[AES256_GCM,data:bZfUTNOta/TuHpR1bsAHV8NFZSFgU1szzN9Ue/mzwMMGRqdh9ORUO8gIT+B3JMVEqNo=,iv:SVaMY2QK8lWGtLuUAXKWKxpfkRrvPBh3jhH9PFMFsuM=,tag:OwdGA0lieHTxe4GfDWqQXg==,type:str] gitea-mailgun-smtp-password: ENC[AES256_GCM,data:dIfcxK5ZQGNqnOfTdVI7FzR9RgP3Ao/bk7XDZULHby58MJumhESELRCkHgKhOSqTAQE=,iv:xjtVQEILVl+XFel+thoS8OvF/fpFYSNtt5MTRUhgyrI=,tag:TJPBQG4xsbHrcdXCbDdejg==,type:str]
mastodon-mailgun-smtp-password: ENC[AES256_GCM,data:h2SSa/053BBIo3Y03TB+1SW6C9DFighMVgY1jzGcUZLhiZ/jd2YbTYlq83Nbb5GBZAY=,iv:9BJuVSfOC48K69kDLUjr1oK3g0xSKAxlzDI/py3STt8=,tag:DTE2OemwbZ0U59wF/9NQjA==,type:str] mastodon-mailgun-smtp-password: ENC[AES256_GCM,data:h2SSa/053BBIo3Y03TB+1SW6C9DFighMVgY1jzGcUZLhiZ/jd2YbTYlq83Nbb5GBZAY=,iv:9BJuVSfOC48K69kDLUjr1oK3g0xSKAxlzDI/py3STt8=,tag:DTE2OemwbZ0U59wF/9NQjA==,type:str]
sops: sops:
kms: [] kms: []
@ -96,8 +96,8 @@ sops:
cHhHRGJIRDlsMEp2RzgxTWkyaWovbkEKnEzQrhYmdxjwa8bDGgVnHBoNXrdb8JDy cHhHRGJIRDlsMEp2RzgxTWkyaWovbkEKnEzQrhYmdxjwa8bDGgVnHBoNXrdb8JDy
EOkYPEiHlscMfsGnUhbujoLXEveIrLzukWgKcRNmS5fTyG4e2eP/cw== EOkYPEiHlscMfsGnUhbujoLXEveIrLzukWgKcRNmS5fTyG4e2eP/cw==
-----END AGE ENCRYPTED FILE----- -----END AGE ENCRYPTED FILE-----
lastmodified: "2024-03-16T11:03:13Z" lastmodified: "2024-01-01T16:13:02Z"
mac: ENC[AES256_GCM,data:XlpAHjvUnnz3NxZnNxlMGELsPjHL648fcs1mbP3KZQLthkLdERjT0BcuqKsY6X+s3CNEET18IKWGiBZPA+iFLAWAzHl+qNDm0WNZv05ECgz+BeNGH6e9FqqtSNIPmnSYfXqyHz/Psg1T5l+N6QK1dRl5PVeO8Bxs3G3H6iZgLOM=,iv:wswvHl6yK/BYW8zf53t18gYz5WNvULaRj2lyHVeuO2A=,tag:pJzh11seJQ64HCiIMhtzdQ==,type:str] mac: ENC[AES256_GCM,data:YMQ2xiuiXoCAzuGGlm/KiEEjjZBHu7i+5Px2YibwSATBeEais9SZFqQx0qmIQw+VGdGAwVo8tQQ5Ikg5YJbHNEetanXbV1UJtMBBUb8m35lras+yXmeveOeKC/f46oa0DCPVuCDqkzEWOAk2NMZnfR5iuWBaZ6rvIhGnqlXodK8=,iv:UkTovxMi25Jfz8JzQE3W+Ar6w7ybBAJQG+9j6RWj/2M=,tag:RRSqNAv3OiMahG2oYZSJvA==,type:str]
pgp: [] pgp: []
unencrypted_suffix: _unencrypted unencrypted_suffix: _unencrypted
version: 3.8.1 version: 3.7.3

View file

@ -1,26 +1,36 @@
{ config, pkgs, inputs, lib, system, ... }: { {
config,
pkgs,
inputs,
lib,
system,
...
}: {
networking.hostName = "foryog"; networking.hostName = "foryog";
imports = [ imports = [
./hardware-configuration.nix ./hardware-configuration.nix
../../backups.nix ../../backups.nix
../../boot.nix ../../boot.nix
../../emacs
../../git ../../git
../../gnome
../../gui ../../gui
../../kde ../../gui/vscode
../../libvirt.nix
../../mercurial
../../vim ../../vim
../../zsh ../../zsh
]; ];
fileSystems."/" = { options = [ "compress=zstd" ]; }; fileSystems."/" = {options = ["compress=zstd"];};
services.restic.backups.home-to-b2 = { services.restic.backups.home-to-b2 = {
repository = lib.mkForce "b2:cyplo-restic-foureighty:/"; repository = lib.mkForce "b2:cyplo-restic-foureighty:/";
}; };
boot.kernelParams = boot.kernelParams = ["initcall_debug" ''dyndbg="file suspend.c +p"'' "no_console_suspend"];
[ "initcall_debug" ''dyndbg="file suspend.c +p"'' "no_console_suspend" ];
boot.tmp.cleanOnBoot = true; boot.tmp.cleanOnBoot = true;
boot.binfmt.emulatedSystems = [ "aarch64-linux" ]; boot.binfmt.emulatedSystems = ["aarch64-linux"];
boot.plymouth = { boot.plymouth = {
enable = true; enable = true;
logo = ./boot.png; logo = ./boot.png;
@ -36,10 +46,21 @@
hardware.trackpoint.enable = true; hardware.trackpoint.enable = true;
hardware.keyboard.qmk.enable = true; hardware.keyboard.qmk.enable = true;
services.udev.packages = [ pkgs.qmk-udev-rules ]; services.udev.packages = [pkgs.qmk-udev-rules];
services.fprintd = { enable = true; }; services.xserver = {
libinput = {
enable = true;
touchpad = {
tapping = true;
naturalScrolling = false;
middleEmulation = false;
disableWhileTyping = true;
};
};
};
services.fprintd = {enable = true;};
programs.ccache.enable = true; programs.ccache.enable = true;
hardware.opengl.extraPackages = with pkgs; [ libva ]; hardware.opengl.extraPackages = with pkgs; [libva];
programs.steam.enable = true; programs.steam.enable = true;
nixpkgs.config.allowUnfreePredicate = pkg: nixpkgs.config.allowUnfreePredicate = pkg:
builtins.elem (lib.getName pkg) [ builtins.elem (lib.getName pkg) [
@ -53,11 +74,14 @@
"vscode" "vscode"
]; ];
home-manager.users.cyryl = { ... }: { home-manager.users.cyryl = {...}: {
imports = [ ../../home-manager/programs/kitty.nix ]; imports = [
../../home-manager/programs/kitty.nix
../../home-manager/programs/helix.nix
];
home.packages = home.packages =
(with inputs.nixpkgs-master.legacyPackages."${system}"; [ bisq-desktop ]) (with inputs.nixpkgs-master.legacyPackages."${system}"; [bisq-desktop])
++ (with pkgs; [ lutris ]) ++ (with pkgs; [lutris])
++ (with inputs.endless-sky.legacyPackages."${system}"; [ endless-sky ]); ++ (with inputs.endless-sky.legacyPackages."${system}"; [endless-sky]);
}; };
} }

View file

@ -1,8 +1,12 @@
{ config, pkgs, ... }: { {
config,
pkgs,
...
}: {
console.keyMap = "pl2"; console.keyMap = "pl2";
imports = [ ./tailscale ]; imports = [./tailscale];
services = { services = {
udev.packages = [ pkgs.android-udev-rules ]; udev.packages = [pkgs.android-udev-rules];
ratbagd.enable = true; ratbagd.enable = true;
gvfs.enable = true; gvfs.enable = true;
@ -21,5 +25,23 @@
}; };
geoclue2.enable = true; geoclue2.enable = true;
xserver = {
enable = true;
layout = "pl";
xkbOptions = "caps:ctrl_modifier";
xkbVariant = "";
libinput = {
enable = true;
touchpad = {
naturalScrolling = false;
disableWhileTyping = true;
};
};
deviceSection = ''
Option "TearFree" "true"
Option "AccelMethod" "sna"
'';
};
}; };
} }

View file

@ -1,8 +1,16 @@
{ config, pkgs, discord, inputs, nixpkgs-nixos-unstable {
, nixpkgs-nixos-stable-and-unfree, nixpkgs-nixos-unstable-and-unfree, ... }: { config,
pkgs,
discord,
inputs,
nixpkgs-nixos-unstable,
nixpkgs-nixos-stable-and-unfree,
nixpkgs-nixos-unstable-and-unfree,
...
}: {
security.chromiumSuidSandbox.enable = true; security.chromiumSuidSandbox.enable = true;
home-manager.users.cyryl = { ... }: { home-manager.users.cyryl = {...}: {
gtk = { gtk = {
enable = true; enable = true;
iconTheme = { iconTheme = {
@ -10,15 +18,21 @@
package = pkgs.gnome3.adwaita-icon-theme; package = pkgs.gnome3.adwaita-icon-theme;
}; };
}; };
qt = { enable = true; }; qt = {
enable = true;
platformTheme = "gnome";
style.name = "adwaita-dark";
style.package = pkgs.adwaita-qt;
};
imports = [ ]; imports = [];
programs.chromium.enable = true; programs.chromium.enable = true;
programs.firefox.enable = true; programs.firefox.enable = true;
home.packages = (with pkgs; home.packages =
(with pkgs;
with pkgs.gnome3; with pkgs.gnome3;
with pkgs.python39Packages; [ with pkgs.python38Packages; [
anarchism anarchism
calibre calibre
cheese cheese
@ -71,12 +85,9 @@
yubikey-manager-qt yubikey-manager-qt
yubikey-personalization yubikey-personalization
yubikey-personalization-gui yubikey-personalization-gui
]) ++ (with nixpkgs-nixos-unstable; [ gnucash thunderbird ]) ])
++ [ nixpkgs-nixos-stable-and-unfree.discord ] ++ (with nixpkgs-nixos-unstable; [gnucash thunderbird])
++ (with nixpkgs-nixos-unstable-and-unfree; [ ++ [nixpkgs-nixos-stable-and-unfree.discord]
hopper ++ (with nixpkgs-nixos-unstable-and-unfree; [hopper jetbrains.rust-rover jetbrains.clion]);
jetbrains.rust-rover
jetbrains.clion
]);
}; };
} }

View file

@ -31,7 +31,7 @@
url = "https://github.com/vadimcn/vscode-lldb/releases/download/v1.6.10/codelldb-${pkgs.system}.vsix"; url = "https://github.com/vadimcn/vscode-lldb/releases/download/v1.6.10/codelldb-${pkgs.system}.vsix";
sha256 = "sha256-QWbpe6ofacjrTCyWSKljwHDWWeHGmKNqi7cpw8Qy5Tw="; sha256 = "sha256-QWbpe6ofacjrTCyWSKljwHDWWeHGmKNqi7cpw8Qy5Tw=";
}; };
buildInputs = with pkgs; [llvm lldb python39 autoPatchelfHook]; buildInputs = with pkgs; [llvm lldb python38 autoPatchelfHook];
}) })
] ]
++ pkgs.vscode-utils.extensionsFromVscodeMarketplace [ ++ pkgs.vscode-utils.extensionsFromVscodeMarketplace [

View file

@ -6,6 +6,7 @@
}: { }: {
services.gpg-agent = { services.gpg-agent = {
enable = true; enable = true;
pinentryFlavor = "curses";
}; };
home.packages = with pkgs; [ home.packages = with pkgs; [
appimage-run appimage-run

View file

@ -28,16 +28,19 @@
sync_address = "https://atuin.cyplo.dev"; sync_address = "https://atuin.cyplo.dev";
search_mode = "fuzzy"; search_mode = "fuzzy";
}; };
flags = ["--disable-up-arrow"]; # flags = [ "--disable-up-arrow" ];
}; };
go.enable = true; go.enable = true;
bat.enable = true; bat.enable = true;
browserpass.enable = true; browserpass.enable = true;
lsd.enable = true;
lsd.enableAliases = true;
eza = { #eza = {
enable = true; # enable = true;
git = true; # enableAliases = true;
icons = true; # git = true;
}; # icons = true;
#};
}; };
} }

16
nixos/kde.nix Normal file
View file

@ -0,0 +1,16 @@
{
config,
pkgs,
...
}: {
services.xserver = {
enable = true;
displayManager.sddm = {
enable = true;
enableHidpi = true;
};
desktopManager.default = "plasma5";
desktopManager.plasma5.enable = true;
};
users.users.cyryl.packages = with pkgs; [];
}

View file

@ -1,9 +0,0 @@
{
config,
pkgs,
...
}: {
imports = [./system.nix];
home-manager.users.cyryl = {...}: {imports = [./home.nix];};
}

View file

@ -1,11 +0,0 @@
{ config, pkgs, ... }: {
services = {
kdeconnect.enable = true;
kdeconnect.indicator = true;
};
home.packages = [ ];
dconf.settings = { };
}

View file

@ -1,24 +0,0 @@
{ config, pkgs, inputs, system, ... }:
let
master = inputs.nixpkgs-master;
pkgs = master.legacyPackages."${system}";
in {
disabledModules = [ ];
imports = [ ];
services.flatpak.enable = true;
services.desktopManager.plasma6.enable = true;
services.xserver = {
enable = true;
displayManager.sddm = {
enable = true;
enableHidpi = true;
wayland.enable = true;
};
};
users.users.cyryl.packages = with pkgs; [ ];
programs.kdeconnect.enable = true;
}

View file

@ -1,4 +1,8 @@
{ config, pkgs, ... }: { {
config,
pkgs,
...
}: {
programs.atuin.enableZshIntegration = true; programs.atuin.enableZshIntegration = true;
programs.zsh = { programs.zsh = {
enable = true; enable = true;
@ -10,12 +14,12 @@
share = true; share = true;
}; };
autosuggestion.enable = true; enableAutosuggestions = true;
enableCompletion = true; enableCompletion = true;
oh-my-zsh = { oh-my-zsh = {
enable = true; enable = true;
plugins = [ "vi-mode" "git" "python" "history-substring-search" "tmux" ]; plugins = ["vi-mode" "git" "python" "history-substring-search" "tmux"];
}; };
initExtra = '' initExtra = ''
@ -65,7 +69,7 @@
programs.direnv = { programs.direnv = {
enable = true; enable = true;
enableZshIntegration = true; enableZshIntegration = true;
nix-direnv = { enable = true; }; nix-direnv = {enable = true;};
}; };
home.file.".config/starship.toml".text = '' home.file.".config/starship.toml".text = ''