Compare commits

...

27 Commits

Author SHA1 Message Date
andromeda
4fa6df2cde add ipv6 to openvpn 2026-01-14 05:32:49 +01:00
andromeda
038a82e400 openvpn-init 2026-01-12 09:07:47 +01:00
mtgmonkey
e78f3510af bump blog 2025-12-26 19:02:31 +01:00
mtgmonkey
5d5fff2da9 bump site 2025-12-18 23:30:53 +01:00
mtgmonkey
52df09e7e1 remove js from personal site 2025-12-18 23:16:46 +01:00
mtgmonkey
5200880cd0 add nixwebr.ing 2025-12-18 22:48:05 +01:00
mtgmonkey
f1eeeb5eee bump blog 2025-12-18 14:39:32 +01:00
mtgmonkey
fe1cee54c3 bump blog 2025-12-18 14:16:25 +01:00
mtgmonkey
09d373a5f5 fix issue where Hauptseite served 404 2025-12-18 11:15:36 +01:00
mtgmonkey
2b841f6af5 update Hauptseite 2025-12-18 11:06:04 +01:00
mtgmonkey
a289d3a2ef update flake inputs from git.mtgmonkey.net; blog 2025-12-18 00:15:42 +01:00
mtgmonkey
b0aac26589 not forgejo, rather gitea 2025-12-14 00:02:43 +01:00
mtgmonkey
7ced4dc2fe forgejo, update 2025-12-13 22:36:14 +01:00
mtgmonkey
8e1895f1b1 idek, random commit 2025-12-11 19:40:50 +00:00
mtgmonkey
6e30000ce5 blog ig idfk 2025-08-28 05:09:43 +00:00
mtgmonkey
7cef5d8798 bump best-blog 2025-06-19 09:53:24 -04:00
mtgmonkey
3f5ad1a3df change from Andromeda/blog to Andromeda/best-blog 2025-06-19 06:27:03 -04:00
mtgmonkey
39b987332b fix merge conflicts? 2025-06-18 14:04:49 -04:00
mtgmonkey
3c96c9818c update lockfile, gitiffy 2025-06-18 13:32:49 -04:00
mtgmonkey
91206fb3c0 add forgejo 2025-06-18 15:45:04 +00:00
mtgmonkey
de1d958778 fix breaking change pushed in bdc3a22 2025-06-17 14:23:03 +00:00
mtgmonkey
dbec636ab7 updated all the systemd daemons 2025-06-17 14:05:43 +00:00
mtgmonkey
bdc3a22570 add git user to rgit service 2025-06-16 21:20:42 +00:00
mtgmonkey
56af2b408c add ipv6 2025-06-16 20:40:06 +00:00
mtgmonkey
8af386e521 add ports for rgit 2025-06-16 20:13:51 +00:00
mtgmonkey
7865de7103 Merge remote-tracking branch 'origin' 2025-06-12 10:53:17 +00:00
mtgmonkey
1fdb3a8599 fix translation problem 2025-06-12 10:52:11 +00:00
18 changed files with 725 additions and 95 deletions

13
cachix.nix Normal file
View File

@@ -0,0 +1,13 @@
# WARN: this file will get overwritten by $ cachix use <name>
{ pkgs, lib, ... }:
let
folder = ./cachix;
toImport = name: value: folder + ("/" + name);
filterCaches = key: value: value == "regular" && lib.hasSuffix ".nix" key;
imports = lib.mapAttrsToList toImport (lib.filterAttrs filterCaches (builtins.readDir folder));
in {
inherit imports;
nix.settings.substituters = ["https://cache.nixos.org/"];
}

13
cachix/rgit.nix Normal file
View File

@@ -0,0 +1,13 @@
{
nix = {
settings = {
substituters = [
"https://rgit.cachix.org"
];
trusted-public-keys = [
"rgit.cachix.org-1:3Wva/GHhrlhbYx+ObbEYQSYq1Yzk8x9OAvEvcYazgL0="
];
};
};
}

View File

@@ -12,7 +12,8 @@
networking.domain = ""; networking.domain = "";
networking.firewall = { networking.firewall = {
enable = true; enable = true;
allowedTCPPorts = [80 443]; allowedTCPPorts = [80 443 9418 25565];
allowedUDPPorts = [80 443 9418 25565];
}; };
boot.loader.grub.devices = ["nodev"]; boot.loader.grub.devices = ["nodev"];
@@ -34,12 +35,6 @@
''; '';
}; };
services.fail2ban = {
enable = true;
maxretry = 10;
bantime-increment.enable = true;
};
users.users.mtgmonkey = { users.users.mtgmonkey = {
isNormalUser = true; isNormalUser = true;
description = "mtgmonkey"; description = "mtgmonkey";

309
flake.lock generated Executable file → Normal file
View File

@@ -1,21 +1,86 @@
{ {
"nodes": { "nodes": {
"elmskell-blog": { "andromeda-nook": {
"inputs": { "inputs": {
"nixpkgs": "nixpkgs" "nixpkgs": "nixpkgs"
}, },
"locked": { "locked": {
"lastModified": 1749395936, "lastModified": 1766772071,
"narHash": "sha256-tEqZKBzQbENlyIDvVMWcnhifjEQkaEzK3eKDQWCbt58=", "narHash": "sha256-PuzrOsLDIWFmmxf/qzCpvZuXjw89TrKXODZ8ORl99rk=",
"ref": "refs/heads/master", "ref": "refs/heads/master",
"rev": "36fa8afd57449cacdc0535417c8d20fb6b702348", "rev": "c86d0a733a30e92e835a1a59b9e0f8e629325ad7",
"revCount": 9, "revCount": 7,
"type": "git", "type": "git",
"url": "file:///var/lib/git-server/blog.git" "url": "https://git.mtgmonkey.net/Andromeda/nook"
}, },
"original": { "original": {
"type": "git", "type": "git",
"url": "file:///var/lib/git-server/blog.git" "url": "https://git.mtgmonkey.net/Andromeda/nook"
}
},
"auto-openvpn": {
"locked": {
"lastModified": 1756224566,
"narHash": "sha256-SW/LESixI4cmSCR8uk3ZtLJpv4G4qkzDlP2EAUcp9to=",
"owner": "fin444",
"repo": "auto-openvpn.nix",
"rev": "cbbfdc0b203633f32511d1060c13e4f64c2f0bc5",
"type": "github"
},
"original": {
"owner": "fin444",
"repo": "auto-openvpn.nix",
"type": "github"
}
},
"blobs": {
"flake": false,
"locked": {
"lastModified": 1604995301,
"narHash": "sha256-wcLzgLec6SGJA8fx1OEN1yV/Py5b+U5iyYpksUY/yLw=",
"owner": "simple-nixos-mailserver",
"repo": "blobs",
"rev": "2cccdf1ca48316f2cfd1c9a0017e8de5a7156265",
"type": "gitlab"
},
"original": {
"owner": "simple-nixos-mailserver",
"repo": "blobs",
"type": "gitlab"
}
},
"blog": {
"inputs": {
"nixpkgs": "nixpkgs_2"
},
"locked": {
"lastModified": 1766065119,
"narHash": "sha256-yW5sym1Yjj0u9QhLzfWWDpD50lRmUCpxL9ss9nyONgU=",
"ref": "refs/heads/master",
"rev": "dd5a2fbd3e276ebdd6f6a9fcc380eb56abba2a26",
"revCount": 60,
"type": "git",
"url": "https://git.mtgmonkey.net/Andromeda/blog"
},
"original": {
"type": "git",
"url": "https://git.mtgmonkey.net/Andromeda/blog"
}
},
"flake-compat": {
"flake": false,
"locked": {
"lastModified": 1747046372,
"narHash": "sha256-CIVLLkVgvHYbgI2UpXvIIBJ12HWgX+fjA8Xf8PUmqCY=",
"owner": "edolstra",
"repo": "flake-compat",
"rev": "9100a0f413b0c601e0533d1d94ffd501ce2e7885",
"type": "github"
},
"original": {
"owner": "edolstra",
"repo": "flake-compat",
"type": "github"
} }
}, },
"flake-utils": { "flake-utils": {
@@ -36,7 +101,122 @@
"type": "github" "type": "github"
} }
}, },
"git-hooks": {
"inputs": {
"flake-compat": [
"simple-nixos-mailserver",
"flake-compat"
],
"gitignore": "gitignore",
"nixpkgs": [
"simple-nixos-mailserver",
"nixpkgs"
]
},
"locked": {
"lastModified": 1758108966,
"narHash": "sha256-ytw7ROXaWZ7OfwHrQ9xvjpUWeGVm86pwnEd1QhzawIo=",
"owner": "cachix",
"repo": "git-hooks.nix",
"rev": "54df955a695a84cd47d4a43e08e1feaf90b1fd9b",
"type": "github"
},
"original": {
"owner": "cachix",
"repo": "git-hooks.nix",
"type": "github"
}
},
"gitignore": {
"inputs": {
"nixpkgs": [
"simple-nixos-mailserver",
"git-hooks",
"nixpkgs"
]
},
"locked": {
"lastModified": 1709087332,
"narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=",
"owner": "hercules-ci",
"repo": "gitignore.nix",
"rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "gitignore.nix",
"type": "github"
}
},
"jank-client": {
"inputs": {
"nixpkgs": "nixpkgs_3"
},
"locked": {
"lastModified": 1749606892,
"narHash": "sha256-ZGUUWNORko3QFy9p/2mc4voJ65/11Joy6Au79+TwxPw=",
"ref": "refs/heads/main",
"rev": "0e59a339c813bcf1e9969344d8b50ed380231552",
"revCount": 1179,
"type": "git",
"url": "https://git.mtgmonkey.net/Andromeda/jank-client-fork"
},
"original": {
"type": "git",
"url": "https://git.mtgmonkey.net/Andromeda/jank-client-fork"
}
},
"math-project": {
"inputs": {
"nixpkgs": "nixpkgs_4"
},
"locked": {
"lastModified": 1750258769,
"narHash": "sha256-BazJgo04yFqFfp2AA0Tfba+nBAeaNddQJBdLghVJskk=",
"ref": "refs/heads/master",
"rev": "fa0e8ca47dd5341d24d8aae90a0bc28a689c3d46",
"revCount": 6,
"type": "git",
"url": "https://git.mtgmonkey.net/Andromeda/math-project"
},
"original": {
"type": "git",
"url": "https://git.mtgmonkey.net/Andromeda/math-project"
}
},
"nixpkgs": { "nixpkgs": {
"locked": {
"lastModified": 1765934234,
"narHash": "sha256-pJjWUzNnjbIAMIc5gRFUuKCDQ9S1cuh3b2hKgA7Mc4A=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "af84f9d270d404c17699522fab95bbf928a2d92f",
"type": "github"
},
"original": {
"id": "nixpkgs",
"ref": "nixpkgs-unstable",
"type": "indirect"
}
},
"nixpkgs-25_05": {
"locked": {
"lastModified": 1759143472,
"narHash": "sha256-TvODmeR2W7yX/JmOCmP+lAFNkTT7hAxYcF3Kz8SZV3w=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "5ed4e25ab58fd4c028b59d5611e14ea64de51d23",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-25.05",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1749143949, "lastModified": 1749143949,
"narHash": "sha256-QuUtALJpVrPnPeozlUG/y+oIMSLdptHxb3GK6cpSVhA=", "narHash": "sha256-QuUtALJpVrPnPeozlUG/y+oIMSLdptHxb3GK6cpSVhA=",
@@ -51,23 +231,52 @@
"type": "indirect" "type": "indirect"
} }
}, },
"nixpkgs_2": { "nixpkgs_3": {
"locked": { "locked": {
"lastModified": 1749373575, "lastModified": 1749285348,
"narHash": "sha256-/3nvhGaUMG1A6zG185QHyTFR2fMiyffxU7VdMYk5qj0=", "narHash": "sha256-frdhQvPbmDYaScPFiCnfdh3B/Vh81Uuoo0w5TkWmmjU=",
"owner": "nixos", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "6a8d437617048567166f83b32d07ba73aeb2d125", "rev": "3e3afe5174c561dee0df6f2c2b2236990146329f",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "nixos", "id": "nixpkgs",
"ref": "release-25.05", "ref": "nixos-unstable",
"repo": "nixpkgs", "type": "indirect"
"type": "github"
} }
}, },
"nixpkgs_3": { "nixpkgs_4": {
"locked": {
"lastModified": 1748889542,
"narHash": "sha256-Hb4iMhIbjX45GcrgOp3b8xnyli+ysRPqAgZ/LZgyT5k=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "10d7f8d34e5eb9c0f9a0485186c1ca691d2c5922",
"type": "github"
},
"original": {
"id": "nixpkgs",
"ref": "nixos-25.05",
"type": "indirect"
}
},
"nixpkgs_5": {
"locked": {
"lastModified": 1765472234,
"narHash": "sha256-9VvC20PJPsleGMewwcWYKGzDIyjckEz8uWmT0vCDYK0=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "2fbfb1d73d239d2402a8fe03963e37aab15abe8b",
"type": "github"
},
"original": {
"id": "nixpkgs",
"ref": "nixos-unstable",
"type": "indirect"
}
},
"nixpkgs_6": {
"locked": { "locked": {
"lastModified": 1714253743, "lastModified": 1714253743,
"narHash": "sha256-mdTQw2XlariysyScCv2tTE45QSU9v/ezLcHJ22f0Nxc=", "narHash": "sha256-mdTQw2XlariysyScCv2tTE45QSU9v/ezLcHJ22f0Nxc=",
@@ -83,13 +292,29 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_4": { "nixpkgs_7": {
"locked": { "locked": {
"lastModified": 1746141548, "lastModified": 1759036355,
"narHash": "sha256-IgBWhX7A2oJmZFIrpRuMnw5RAufVnfvOgHWgIdds+hc=", "narHash": "sha256-0m27AKv6ka+q270dw48KflE0LwQYrO7Fm4/2//KCVWg=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "f02fddb8acef29a8b32f10a335d44828d7825b78", "rev": "e9f00bd893984bc8ce46c895c3bf7cac95331127",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_8": {
"locked": {
"lastModified": 1760524057,
"narHash": "sha256-EVAqOteLBFmd7pKkb0+FIUyzTF61VKi7YmvP1tw4nEw=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "544961dfcce86422ba200ed9a0b00dd4b1486ec5",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -101,7 +326,7 @@
}, },
"noshell": { "noshell": {
"inputs": { "inputs": {
"nixpkgs": "nixpkgs_3" "nixpkgs": "nixpkgs_6"
}, },
"locked": { "locked": {
"lastModified": 1717396029, "lastModified": 1717396029,
@@ -119,23 +344,51 @@
}, },
"root": { "root": {
"inputs": { "inputs": {
"elmskell-blog": "elmskell-blog", "andromeda-nook": "andromeda-nook",
"nixpkgs": "nixpkgs_2", "auto-openvpn": "auto-openvpn",
"blog": "blog",
"jank-client": "jank-client",
"math-project": "math-project",
"nixpkgs": "nixpkgs_5",
"noshell": "noshell", "noshell": "noshell",
"simple-nixos-mailserver": "simple-nixos-mailserver",
"spacebar-server": "spacebar-server" "spacebar-server": "spacebar-server"
} }
}, },
"simple-nixos-mailserver": {
"inputs": {
"blobs": "blobs",
"flake-compat": "flake-compat",
"git-hooks": "git-hooks",
"nixpkgs": "nixpkgs_7",
"nixpkgs-25_05": "nixpkgs-25_05"
},
"locked": {
"lastModified": 1759489698,
"narHash": "sha256-2lT2i5ha23I2vrolEaBaAS/63ChgZPh181Awt6q1bDY=",
"owner": "simple-nixos-mailserver",
"repo": "nixos-mailserver",
"rev": "6005d88bed7a5418f9772b4058a73cd0fd1e69a1",
"type": "gitlab"
},
"original": {
"owner": "simple-nixos-mailserver",
"ref": "master",
"repo": "nixos-mailserver",
"type": "gitlab"
}
},
"spacebar-server": { "spacebar-server": {
"inputs": { "inputs": {
"flake-utils": "flake-utils", "flake-utils": "flake-utils",
"nixpkgs": "nixpkgs_4" "nixpkgs": "nixpkgs_8"
}, },
"locked": { "locked": {
"lastModified": 1748414795, "lastModified": 1761916341,
"narHash": "sha256-nClmjajuaMVV02Rn7xqZWy5pwLmGw7/MF3RDGkYDuYQ=", "narHash": "sha256-NalvODcjJq3MutPu5nyiXqnYmz2m8yiQ6dJ8s/i+9aA=",
"owner": "spacebarchat", "owner": "spacebarchat",
"repo": "server", "repo": "server",
"rev": "f03c6209a42ae3e922bdb86954de04f1ae6daaa8", "rev": "c8fab8e8ff4c689b025c8b140135e9ae406229d9",
"type": "github" "type": "github"
}, },
"original": { "original": {

232
flake.lock.bak Normal file
View File

@@ -0,0 +1,232 @@
{
"nodes": {
"blog": {
"inputs": {
"nixpkgs": "nixpkgs"
},
"locked": {
"lastModified": 1754950153,
"narHash": "sha256-puOP2m2ixs9nzId8CnxHvteU/iMLRJtveigb2njjrPE=",
"ref": "refs/heads/master",
"rev": "ea162211d17489133552c12cee9ffae2b4c11e5e",
"revCount": 30,
"type": "git",
"url": "https://git.mtgmonkey.net/Andromeda/blog.git"
},
"original": {
"type": "git",
"url": "https://git.mtgmonkey.net/Andromeda/blog.git"
}
},
"flake-utils": {
"inputs": {
"systems": "systems"
},
"locked": {
"lastModified": 1731533236,
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"jank-client": {
"inputs": {
"nixpkgs": "nixpkgs_2"
},
"locked": {
"lastModified": 1749606892,
"narHash": "sha256-ZGUUWNORko3QFy9p/2mc4voJ65/11Joy6Au79+TwxPw=",
"ref": "refs/heads/main",
"rev": "0e59a339c813bcf1e9969344d8b50ed380231552",
"revCount": 1179,
"type": "git",
"url": "https://git.mtgmonkey.net/Andromeda/jank-client-fork.git"
},
"original": {
"type": "git",
"url": "https://git.mtgmonkey.net/Andromeda/jank-client-fork.git"
}
},
"math-project": {
"inputs": {
"nixpkgs": "nixpkgs_3"
},
"locked": {
"lastModified": 1750258769,
"narHash": "sha256-BazJgo04yFqFfp2AA0Tfba+nBAeaNddQJBdLghVJskk=",
"ref": "refs/heads/master",
"rev": "fa0e8ca47dd5341d24d8aae90a0bc28a689c3d46",
"revCount": 6,
"type": "git",
"url": "https://git.mtgmonkey.net/Andromeda/math-project.git"
},
"original": {
"type": "git",
"url": "https://git.mtgmonkey.net/Andromeda/math-project.git"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1749143949,
"narHash": "sha256-QuUtALJpVrPnPeozlUG/y+oIMSLdptHxb3GK6cpSVhA=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "d3d2d80a2191a73d1e86456a751b83aa13085d7d",
"type": "github"
},
"original": {
"id": "nixpkgs",
"ref": "nixos-unstable",
"type": "indirect"
}
},
"nixpkgs_2": {
"locked": {
"lastModified": 1749285348,
"narHash": "sha256-frdhQvPbmDYaScPFiCnfdh3B/Vh81Uuoo0w5TkWmmjU=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "3e3afe5174c561dee0df6f2c2b2236990146329f",
"type": "github"
},
"original": {
"id": "nixpkgs",
"ref": "nixos-unstable",
"type": "indirect"
}
},
"nixpkgs_3": {
"locked": {
"lastModified": 1748889542,
"narHash": "sha256-Hb4iMhIbjX45GcrgOp3b8xnyli+ysRPqAgZ/LZgyT5k=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "10d7f8d34e5eb9c0f9a0485186c1ca691d2c5922",
"type": "github"
},
"original": {
"id": "nixpkgs",
"ref": "nixos-25.05",
"type": "indirect"
}
},
"nixpkgs_4": {
"locked": {
"lastModified": 1754214453,
"narHash": "sha256-Q/I2xJn/j1wpkGhWkQnm20nShYnG7TI99foDBpXm1SY=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "5b09dc45f24cf32316283e62aec81ffee3c3e376",
"type": "github"
},
"original": {
"id": "nixpkgs",
"ref": "nixos-unstable",
"type": "indirect"
}
},
"nixpkgs_5": {
"locked": {
"lastModified": 1714253743,
"narHash": "sha256-mdTQw2XlariysyScCv2tTE45QSU9v/ezLcHJ22f0Nxc=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "58a1abdbae3217ca6b702f03d3b35125d88a2994",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_6": {
"locked": {
"lastModified": 1746141548,
"narHash": "sha256-IgBWhX7A2oJmZFIrpRuMnw5RAufVnfvOgHWgIdds+hc=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "f02fddb8acef29a8b32f10a335d44828d7825b78",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"noshell": {
"inputs": {
"nixpkgs": "nixpkgs_5"
},
"locked": {
"lastModified": 1717396029,
"narHash": "sha256-NPIhvnTYkJZqTY+aabbZ6CAaMAgG6IISvh7GZo1MTfQ=",
"owner": "viperML",
"repo": "noshell",
"rev": "4d194d838a50ea106cd0e47c024e47afc154ab42",
"type": "github"
},
"original": {
"owner": "viperML",
"repo": "noshell",
"type": "github"
}
},
"root": {
"inputs": {
"blog": "blog",
"jank-client": "jank-client",
"math-project": "math-project",
"nixpkgs": "nixpkgs_4",
"noshell": "noshell",
"spacebar-server": "spacebar-server"
}
},
"spacebar-server": {
"inputs": {
"flake-utils": "flake-utils",
"nixpkgs": "nixpkgs_6"
},
"locked": {
"lastModified": 1748414795,
"narHash": "sha256-nClmjajuaMVV02Rn7xqZWy5pwLmGw7/MF3RDGkYDuYQ=",
"owner": "spacebarchat",
"repo": "server",
"rev": "f03c6209a42ae3e922bdb86954de04f1ae6daaa8",
"type": "github"
},
"original": {
"owner": "spacebarchat",
"repo": "server",
"type": "github"
}
},
"systems": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
}
},
"root": "root",
"version": 7
}

View File

@@ -1,23 +1,28 @@
{ {
description = "server flake"; description = "server flake";
inputs = { inputs = {
nixpkgs.url = "github:nixos/nixpkgs/release-25.05"; nixpkgs.url = "nixpkgs/nixos-unstable";
noshell.url = "github:viperML/noshell"; noshell.url = "github:viperML/noshell";
spacebar-server.url = "github:spacebarchat/server"; spacebar-server.url = "github:spacebarchat/server";
simple-nixos-mailserver.url = "gitlab:simple-nixos-mailserver/nixos-mailserver/master";
elmskell-blog.url = "git+file:///var/lib/git-server/blog.git"; auto-openvpn.url = "github:fin444/auto-openvpn.nix";
jank-client.url = "git+file:///var/lib/git-server/jank-client-fork.git"; andromeda-nook.url = "git+https://git.mtgmonkey.net/Andromeda/nook";
math-project.url = "git+file:///var/lib/git-server/math-project.git"; blog.url = "git+https://git.mtgmonkey.net/Andromeda/blog";
jank-client.url = "git+https://git.mtgmonkey.net/Andromeda/jank-client-fork";
math-project.url = "git+https://git.mtgmonkey.net/Andromeda/math-project";
}; };
outputs = { outputs = {
self, self,
nixpkgs, nixpkgs,
noshell, noshell,
elmskell-blog,
spacebar-server, spacebar-server,
simple-nixos-mailserver,
auto-openvpn,
andromeda-nook,
jank-client, jank-client,
math-project, math-project,
blog,
... ...
}: let }: let
system = "x86_64-linux"; system = "x86_64-linux";
@@ -27,30 +32,37 @@
specialArgs = { specialArgs = {
inherit self; inherit self;
inherit system; inherit system;
inherit elmskell-blog;
inherit spacebar-server; inherit spacebar-server;
inherit simple-nixos-mailserver;
inherit auto-openvpn;
inherit math-project;
inherit andromeda-nook;
inherit blog;
ssh-pub-keys = import ./ssh-pub-keys.nix; ssh-pub-keys = import ./ssh-pub-keys.nix;
}; };
modules = [ modules = [
./services/ferron.nix ./configuration.nix
./services/elmskell.nix
./services/blog.nix ./services/blog.nix
# ./services/elmskell.nix
./services/ferron.nix
./services/gitea.nix
# ./services/mailserver.nix
# ./services/minecraft-server.nix
# ./services/rgit.nix
./services/math-project.nix
./services/spacebar.nix
./services/translate.nix
./services/vpn.nix
jank-client.nixosModules.x86_64-linux.default jank-client.nixosModules.x86_64-linux.default
./services/spacebar.nix math-project.nixosModules.x86_64-linux.default
./services/rgit.nix
./services/translate.nix
noshell.nixosModules.default noshell.nixosModules.default
{programs.noshell.enable = true;} simple-nixos-mailserver.nixosModule
{
math-project.nixosModules.default programs.noshell.enable = true;
{programs.math-project.enable = true;} services.math-project.enable = true;
./services/math-project.nix }
./configuration.nix
]; ];
}; };
}; };

View File

@@ -1,5 +1,5 @@
{ {
elmskell-blog, blog,
lib, lib,
pkgs, pkgs,
... ...
@@ -18,13 +18,6 @@
} }
]; ];
}; };
ferron-conf-nix = {
global = {
port = 8181;
secure = false;
wwwroot = "${elmskell-blog.packages.x86_64-linux.default}/wwwroot";
};
};
in { in {
services.anubis = { services.anubis = {
instances.blog = { instances.blog = {
@@ -36,7 +29,7 @@ in {
METRICS_BIND = "[::1]:9182"; METRICS_BIND = "[::1]:9182";
METRICS_BIND_NETWORK = "tcp"; METRICS_BIND_NETWORK = "tcp";
POLICY_FNAME = "/etc/anubis/blog.botPolicies.yaml"; POLICY_FNAME = "/etc/anubis/blog.botPolicies.yaml";
TARGET = "http://localhost:8181"; TARGET = "http://localhost:9345";
}; };
}; };
}; };
@@ -44,15 +37,16 @@ in {
source = (pkgs.formats.yaml {}).generate "" botPolicies-nix; source = (pkgs.formats.yaml {}).generate "" botPolicies-nix;
mode = "644"; mode = "644";
}; };
systemd.services.blog-ferron = { systemd.services.blog = {
serviceConfig = { serviceConfig = {
Type = "simple"; Type = "simple";
ExecStart = "${lib.getExe pkgs.ferron} --config=/etc/blog.ferron.yaml"; ExecStart = "${lib.getExe pkgs.http-server} ${blog.packages.x86_64-linux.default}/wwwroot -p 9345";
RemainAfterExit = true; RemainAfterExit = true;
Restart = "always";
RestartMaxDelaySec = "1m";
RestartSec = "100ms";
RestartSteps = 9;
}; };
}; wantedBy = ["multi-user.target"];
environment.etc."blog.ferron.yaml" = {
source = (pkgs.formats.yaml {}).generate "" ferron-conf-nix;
mode = "644";
}; };
} }

View File

@@ -39,7 +39,12 @@ in {
Type = "simple"; Type = "simple";
ExecStart = "/etc/nixos/services/elmskell/elmskell"; ExecStart = "/etc/nixos/services/elmskell/elmskell";
RemainAfterExit = true; RemainAfterExit = true;
Restart = "always";
RestartMaxDelaySec = "1m";
RestartSec = "100ms";
RestartSteps = 9;
}; };
wantedBy = ["multi-user.target"];
}; };
services.tor = { services.tor = {
enable = true; enable = true;

View File

@@ -1,6 +1,8 @@
{ {
lib, lib,
pkgs, pkgs,
system,
andromeda-nook,
... ...
}: let }: let
ferron-conf-nix = { ferron-conf-nix = {
@@ -15,7 +17,7 @@
hosts = [ hosts = [
{ {
domain = "mtgmonkey.net"; domain = "mtgmonkey.net";
proxyTo = "http://localhost:9080/"; wwwroot = "${andromeda-nook.packages.${system}.default}/wwwroot";
} }
{ {
domain = "blog.mtgmonkey.net"; domain = "blog.mtgmonkey.net";
@@ -41,6 +43,10 @@
domain = "translate.mtgmonkey.net"; domain = "translate.mtgmonkey.net";
proxyTo = "http://localhost:9109/"; proxyTo = "http://localhost:9109/";
} }
{
domain = "mail.mtgmonkey.net";
proxyTo = "http://localhost:6942/";
}
]; ];
}; };
in { in {
@@ -50,6 +56,7 @@ in {
ExecStart = "${lib.getExe pkgs.ferron} --config=/etc/ferron.yaml"; ExecStart = "${lib.getExe pkgs.ferron} --config=/etc/ferron.yaml";
RemainAfterExit = true; RemainAfterExit = true;
}; };
wantedBy = ["multi-user.target"];
}; };
environment.etc."ferron.yaml" = { environment.etc."ferron.yaml" = {

28
services/gitea.nix Executable file
View File

@@ -0,0 +1,28 @@
{
pkgs,
lib,
...
}: {
systemd.services.gitea = {
serviceConfig = {
Type = "simple";
ExecStart = "${lib.getExe pkgs.gitea} -c /etc/gitea/config.ini";
RemainAfterExit = true;
Restart = "always";
RestartMaxDelaySec = "1m";
RestartSec = "100ms";
RestartSteps = 9;
User = "git";
Group = "git";
};
wantedBy = ["multi-user.target"];
};
environment.etc."gitea/config.ini.default" = {
text = ''
WORK_PATH = /var/lib/git-server
[server]
HTTP_PORT = 8000
'';
mode = "644";
};
}

27
services/mailserver.nix Normal file
View File

@@ -0,0 +1,27 @@
{config, ...}: {
mailserver = {
enable = true;
stateVersion = 3;
fqdn = "mail.mtgmonkey.net";
domains = ["mtgmonkey.net"];
loginAccounts = {
"example@mtgmonkey.net" = {
hashedPasswordFile = "/home/mtgmonkey/secrets/example_passhash";
aliases = ["postmaster@mtgmonkey.net"];
};
};
certificateScheme = "manual";
};
services.roundcube = {
enable = true;
hostName = "localhost:6942";
extraConfig = ''
$config['smtp_server'] = tls://${config.mailserver.fqdn}";
$config['smtp_user'] = "%u";
$config['stmp_pass'] = "%p";
'';
};
}

View File

@@ -29,7 +29,7 @@ in {
METRICS_BIND = "[::1]:9283"; METRICS_BIND = "[::1]:9283";
METRICS_BIND_NETWORK = "tcp"; METRICS_BIND_NETWORK = "tcp";
POLICY_FNAME = "/etc/anubis/math-project.botPolicies.yaml"; POLICY_FNAME = "/etc/anubis/math-project.botPolicies.yaml";
TARGET = "http://localhost:8080"; TARGET = "http://localhost:8081";
}; };
}; };
}; };
@@ -42,8 +42,13 @@ in {
systemd.services.math-project = { systemd.services.math-project = {
serviceConfig = { serviceConfig = {
Type = "simple"; Type = "simple";
ExecStart = "${lib.getExe math-project}"; ExecStart = "${lib.getExe math-project.packages.x86_64-linux.default}";
RemainAfterExit = true; RemainAfterExit = true;
Restart = "always";
RestartMaxDelaySec = "1m";
RestartSec = "100ms";
RestartSteps = 9;
}; };
wantedBy = ["multi-user.target"];
}; };
} }

View File

@@ -0,0 +1,8 @@
{
nixpkgs.config.allowUnfree = true;
services.minecraft-server = {
enable = true;
eula = true;
jvmOpts = "-Xms512M -Xmx1024M";
};
}

View File

@@ -1,23 +1,16 @@
{ {rgit, ...}: {
virtualisation.docker = { systemd.services.rgit = {
enable = true; serviceConfig = {
}; Type = "simple";
virtualisation.oci-containers.backend = "docker"; ExecStart = "${rgit.packages.x86_64-linux.default}/bin/rgit -d /var/lib/git-server/.db/rgit-cache.db [::1]:8000 /var/lib/git-server";
virtualisation.oci-containers.containers.rgit = { RemainAfterExit = true;
image = "ghcr.io/w4/rgit:main"; Restart = "always";
ports = [ RestartMaxDelay = "1m";
"8000:8000" RestartSec = "100ms";
]; RestartSteps = 9;
volumes = [ User = "git";
"/var/lib/git-server:/git:ro" Group = "git";
];
cmd = [
"[::]:8000"
"/git"
"-d /tmp/rgit-cache.db"
];
environment = {
REFRESH_INTERVAL = "5m";
}; };
wantedBy = ["multi-user.target"];
}; };
} }

23
services/rgit.nix.bak Executable file
View File

@@ -0,0 +1,23 @@
{
virtualisation.docker = {
enable = true;
};
virtualisation.oci-containers.backend = "docker";
virtualisation.oci-containers.containers.rgit = {
image = "ghcr.io/w4/rgit:main";
ports = [
"8000:8000"
];
volumes = [
"/var/lib/git-server:/git:ro"
];
cmd = [
"[::]:8000"
"/git"
"-d /tmp/rgit-cache.db"
];
environment = {
REFRESH_INTERVAL = "5m";
};
};
}

View File

@@ -45,7 +45,12 @@ in {
RemainAfterExit = true; RemainAfterExit = true;
User = "spacebar"; User = "spacebar";
Group = "spacebar"; Group = "spacebar";
Restart = "always";
RestartMaxDelaySec = "1m";
RestartSec = "100ms";
RestartSteps = 9;
}; };
wantedBy = ["multi-user.target"];
environment = { environment = {
DATABASE = "/var/lib/spacebar-server/database.db"; DATABASE = "/var/lib/spacebar-server/database.db";
STORAGE_LOCATION = "/var/lib/spacebar-server/files/"; STORAGE_LOCATION = "/var/lib/spacebar-server/files/";

View File

@@ -41,8 +41,13 @@ in {
systemd.services.translate = { systemd.services.translate = {
serviceConfig = { serviceConfig = {
Type = "simple"; Type = "simple";
ExecStart = "${lib.getExe pkgs.libretranslate}"; ExecStart = "${lib.getExe pkgs.libretranslate} --port 8108";
RemainAfterExit = true; RemainAfterExit = true;
Restart = "always";
RestartMaxDelaySec = "1m";
RestartSec = "100ms";
RestartSteps = 9;
}; };
wantedBy = ["multi-user.target"];
}; };
} }

12
services/vpn.nix Normal file
View File

@@ -0,0 +1,12 @@
{auto-openvpn, ...}: {
imports = [
auto-openvpn.nixosModules.auto-openvpn
];
services.auto-openvpn = {
enable = true;
enableIPv6 = true;
interface = "ens18";
address = "173.249.5.230";
users = ["handy" "lenovo"];
};
}