commit 6d52016d9f9d152cf629fa5146ee7429ec1c6013
parent b705cab733d64439a3fd938aed53428425b9feee
Author: Silas Brack <silasbrack@gmail.com>
Date: Sat, 7 Mar 2026 17:59:30 +0100
Testing mailserver
Diffstat:
5 files changed, 100 insertions(+), 66 deletions(-)
diff --git a/flake.lock b/flake.lock
@@ -2,11 +2,11 @@
"nodes": {
"nixpkgs": {
"locked": {
- "lastModified": 1758791193,
- "narHash": "sha256-F8WmEwFoHsnix7rt290R0rFXNJiMbClMZyIC/e+HYf0=",
+ "lastModified": 1767313136,
+ "narHash": "sha256-16KkgfdYqjaeRGBaYsNrhPRRENs0qzkQVUooNHtoy2w=",
"owner": "NixOS",
"repo": "nixpkgs",
- "rev": "25e53aa156d47bad5082ff7618f5feb1f5e02d01",
+ "rev": "ac62194c3917d5f474c1a844b6fd6da2db95077d",
"type": "github"
},
"original": {
@@ -34,11 +34,11 @@
},
"nixpkgs_3": {
"locked": {
- "lastModified": 1758262103,
- "narHash": "sha256-aBGl3XEOsjWw6W3AHiKibN7FeoG73dutQQEqnd/etR8=",
+ "lastModified": 1769740369,
+ "narHash": "sha256-xKPyJoMoXfXpDM5DFDZDsi9PHArf2k5BJjvReYXoFpM=",
"owner": "NixOS",
"repo": "nixpkgs",
- "rev": "12bd230118a1901a4a5d393f9f56b6ad7e571d01",
+ "rev": "6308c3b21396534d8aaeac46179c14c439a89b8a",
"type": "github"
},
"original": {
@@ -113,11 +113,11 @@
"uv2nix": "uv2nix"
},
"locked": {
- "lastModified": 1759589908,
- "narHash": "sha256-TvNAHxRjgtaL8tnGOisoM8GDA9OW/PgprOLcPbgvKo4=",
+ "lastModified": 1760541146,
+ "narHash": "sha256-QQLNQ2vl8LXcs+F8lMxNDpMGc28x5URtaSuU9aikDtg=",
"owner": "silasbrack",
"repo": "simple-web-app",
- "rev": "8ff2082f0f0943ec38b38ddb773246f88be17032",
+ "rev": "c0a11ab37b52e3bf0a8f1e5981500e09abb3c232",
"type": "github"
},
"original": {
@@ -131,11 +131,11 @@
"nixpkgs": "nixpkgs_3"
},
"locked": {
- "lastModified": 1758425756,
- "narHash": "sha256-L3N8zV6wsViXiD8i3WFyrvjDdz76g3tXKEdZ4FkgQ+Y=",
+ "lastModified": 1770145881,
+ "narHash": "sha256-ktjWTq+D5MTXQcL9N6cDZXUf9kX8JBLLBLT0ZyOTSYY=",
"owner": "Mic92",
"repo": "sops-nix",
- "rev": "e0fdaea3c31646e252a60b42d0ed8eafdb289762",
+ "rev": "17eea6f3816ba6568b8c81db8a4e6ca438b30b7c",
"type": "github"
},
"original": {
diff --git a/flake.nix b/flake.nix
@@ -38,7 +38,6 @@
)
];
};
- # development environment (nix develop)
devShells."${system}".default =
let
pkgs = import nixpkgs {
@@ -47,11 +46,13 @@
in
pkgs.mkShell {
buildInputs = with pkgs; [
+ gnumake
age
curl
sops
wireguard-tools
squawk
+ nixfmt-rfc-style
];
};
};
diff --git a/nixos/configuration-debian-2gb-hel1-1.nix b/nixos/configuration-debian-2gb-hel1-1.nix
@@ -1,5 +1,6 @@
{
pkgs,
+ config,
simple-web-app,
...
}:
@@ -53,8 +54,15 @@
time.timeZone = "Europe/Helsinki";
imports = [
- ./simple-web-app.nix
+ # ./simple-web-app.nix
# ./vpn.nix
+ # (builtins.fetchTarball {
+ # # Pick a release version you are interested in and set its hash, e.g.
+ # url = "https://gitlab.com/simple-nixos-mailserver/nixos-mailserver/-/archive/nixos-25.05/nixos-mailserver-nixos-25.05.tar.gz";
+ # # To get the sha256 of the nixos-mailserver tarball, we can use the nix-prefetch-url command:
+ # # release="nixos-25.05"; nix-prefetch-url "https://gitlab.com/simple-nixos-mailserver/nixos-mailserver/-/archive/${release}/nixos-mailserver-${release}.tar.gz" --unpack
+ # sha256 = "0la8v8d9vzhwrnxmmyz3xnb6vm76kihccjyidhfg6qfi3143fiwq";
+ # })
];
sops.defaultSopsFile = ../secrets.yaml;
@@ -105,24 +113,50 @@
};
services.nginx.enable = true;
- services.simple-web-app = {
- enable = true;
- package = simple-web-app.packages."x86_64-linux".default;
- port = 8032;
- };
+ # services.simple-web-app = {
+ # enable = true;
+ # package = simple-web-app.packages."x86_64-linux".default;
+ # port = 8032;
+ # };
- services.karakeep = {
- enable = true;
- extraEnvironment = {
- PORT = "8360";
- DISABLE_SIGNUPS = "true";
- };
- };
- services.nginx.virtualHosts."karakeep.fnarglebeast.com" = {
- forceSSL = true;
- enableACME = true;
- locations."/" = {
- proxyPass = "http://127.0.0.1:8360";
- };
- };
+ # services.karakeep = {
+ # enable = true;
+ # extraEnvironment = {
+ # PORT = "8360";
+ # DISABLE_SIGNUPS = "true";
+ # };
+ # };
+ # services.nginx.virtualHosts."karakeep.fnarglebeast.com" = {
+ # forceSSL = true;
+ # enableACME = true;
+ # locations."/" = {
+ # proxyPass = "http://127.0.0.1:8360";
+ # };
+ # };
+
+ # services.nginx.virtualHosts."mail.silasbrack.com" = {
+ # forceSSL = true;
+ # enableACME = true;
+ # locations."/" = {
+ # proxyPass = "";
+ # };
+ # };
+ # mailserver = {
+ # enable = true;
+ # fqdn = "mail.silasbrack.com";
+ # domains = [ "silasbrack.com" ];
+ #
+ # # Use Let's Encrypt certificates. Note that this needs to set up a stripped
+ # # down nginx and opens port 80.
+ # certificateScheme = "acme-nginx";
+ #
+ # # A list of all login accounts. To create the password hashes, use
+ # # nix-shell -p mkpasswd --run 'mkpasswd -s'
+ # loginAccounts = {
+ # "test@silasbrack.com" = {
+ # hashedPasswordFile = "/home/silas/.test.txt";
+ # # aliases = [ "postmaster@example.com" ];
+ # };
+ # };
+ # };
}
diff --git a/nixos/configuration-nixos-s-1vcpu-512mb-10gb-ams3-01.nix b/nixos/configuration-nixos-s-1vcpu-512mb-10gb-ams3-01.nix
@@ -8,12 +8,6 @@
system.stateVersion = "24.05"; # Do not change lightly!
environment.systemPackages = with pkgs; [
vim
- wget
- curl
- rsync
- rclone
- zip
- unzip
];
nix.settings.experimental-features = [
"nix-command"
@@ -81,35 +75,35 @@
forceSSL = true;
enableACME = true;
};
- virtualHosts."livebook.fnarglebeast.com" = {
- forceSSL = true;
- enableACME = true;
- locations."/" = {
- proxyPass = "http://127.0.0.1:20123";
- proxyWebsockets = true; # needed if you need to use WebSocket
- extraConfig =
- # required when the target is also TLS server with multiple hosts
- "proxy_ssl_server_name on;"
- +
- # required when the server wants to use HTTP Authentication
- "proxy_pass_header Authorization;";
- };
- };
+ # virtualHosts."livebook.fnarglebeast.com" = {
+ # forceSSL = true;
+ # enableACME = true;
+ # locations."/" = {
+ # proxyPass = "http://127.0.0.1:20123";
+ # proxyWebsockets = true; # needed if you need to use WebSocket
+ # extraConfig =
+ # # required when the target is also TLS server with multiple hosts
+ # "proxy_ssl_server_name on;"
+ # +
+ # # required when the server wants to use HTTP Authentication
+ # "proxy_pass_header Authorization;";
+ # };
+ # };
};
- sops.secrets.livebook_password_env_file = { };
- services.livebook = {
- enableUserService = true;
- environment = {
- LIVEBOOK_PORT = 20123;
- LIVEBOOK_IFRAME_PORT = 20124;
- };
- environmentFile = "/run/secrets/livebook_password_env_file";
- extraPackages = with pkgs; [
- gcc
- gnumake
- ];
- };
+ # sops.secrets.livebook_password_env_file = { };
+ # services.livebook = {
+ # enableUserService = true;
+ # environment = {
+ # LIVEBOOK_PORT = 20123;
+ # LIVEBOOK_IFRAME_PORT = 20124;
+ # };
+ # environmentFile = "/run/secrets/livebook_password_env_file";
+ # extraPackages = with pkgs; [
+ # gcc
+ # gnumake
+ # ];
+ # };
sops.secrets.freshrss_password = {
owner = "freshrss";
diff --git a/nixos/vpn.nix b/nixos/vpn.nix
@@ -68,6 +68,11 @@
publicKey = "QE4UoW2vSQMX8o1liA4MSwe4fE5sUB0+Ari5a/CqkSc=";
allowedIPs = [ "10.100.0.7/32" ];
}
+ {
+ # XPS 13
+ publicKey = "ZkRCc3EpJYl0EmRBEAjf9WXCW0JQvlzeq5h7fUn5aEs=";
+ allowedIPs = [ "10.100.0.8/32" ];
+ }
];
};
};