2023-10-01 16:03:02 +02:00
|
|
|
{
|
|
|
|
config,
|
|
|
|
pkgs,
|
2023-10-17 22:41:22 +02:00
|
|
|
lib,
|
2023-11-14 14:42:20 +01:00
|
|
|
project-cloud,
|
2024-03-16 15:27:40 +01:00
|
|
|
nvim,
|
|
|
|
system,
|
2023-10-01 16:03:02 +02:00
|
|
|
...
|
2025-01-10 18:11:42 +01:00
|
|
|
}:
|
|
|
|
{
|
|
|
|
imports = [ ];
|
2023-10-01 16:03:02 +02:00
|
|
|
|
|
|
|
nix.optimise.automatic = true;
|
2025-01-10 18:11:42 +01:00
|
|
|
nix.settings.experimental-features = [
|
|
|
|
"nix-command"
|
|
|
|
"flakes"
|
|
|
|
];
|
2024-09-02 21:50:34 +02:00
|
|
|
system.switch = {
|
|
|
|
enable = false;
|
|
|
|
enableNg = true;
|
|
|
|
};
|
2023-10-01 16:03:02 +02:00
|
|
|
|
|
|
|
# Use the systemd-boot EFI boot loader.
|
|
|
|
boot.loader.systemd-boot.enable = true;
|
2023-11-12 18:05:03 +01:00
|
|
|
boot.loader.systemd-boot.configurationLimit = 2;
|
2023-10-01 16:03:02 +02:00
|
|
|
boot.loader.efi.canTouchEfiVariables = true;
|
|
|
|
boot.kernelPackages = pkgs.linuxPackages_latest;
|
2025-01-10 18:11:42 +01:00
|
|
|
boot.kernelParams = [
|
|
|
|
"ip=dhcp"
|
|
|
|
"console=tty"
|
|
|
|
];
|
2023-11-06 22:26:03 +01:00
|
|
|
boot.kernel.sysctl = {
|
|
|
|
"net.core.default_qdisc" = "fq";
|
|
|
|
"net.ipv4.tcp_congestion_control" = "bbr";
|
|
|
|
};
|
2023-10-01 16:03:02 +02:00
|
|
|
|
2024-04-21 13:53:46 +02:00
|
|
|
boot.initrd = {
|
|
|
|
compressor = "zstd";
|
2025-01-10 18:11:42 +01:00
|
|
|
availableKernelModules = [
|
|
|
|
"virtio-pci"
|
|
|
|
"virtio-gpu"
|
|
|
|
];
|
2024-09-02 22:59:00 +02:00
|
|
|
systemd.enable = true;
|
2024-04-21 13:53:46 +02:00
|
|
|
network = {
|
|
|
|
enable = true;
|
|
|
|
ssh = {
|
|
|
|
enable = true;
|
2025-01-10 18:11:42 +01:00
|
|
|
hostKeys = [ /etc/ssh_dummy_ed25519_key ];
|
|
|
|
authorizedKeyFiles = [ ../nixy/ssh_pubkey ];
|
2024-04-21 13:53:46 +02:00
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2023-10-01 16:03:02 +02:00
|
|
|
# Set your time zone.
|
|
|
|
time.timeZone = "Europe/Berlin";
|
|
|
|
|
|
|
|
users.users.root.initialHashedPassword = "";
|
|
|
|
users.users.root.openssh.authorizedKeys.keys = [
|
2024-04-17 22:27:10 +02:00
|
|
|
(builtins.readFile ../nixy/ssh_pubkey)
|
2023-10-01 16:03:02 +02:00
|
|
|
];
|
|
|
|
|
|
|
|
environment.systemPackages = with pkgs; [
|
|
|
|
curl
|
|
|
|
fd
|
|
|
|
file
|
|
|
|
fzf
|
|
|
|
fzy
|
|
|
|
git
|
2024-03-17 19:33:03 +01:00
|
|
|
nvim.packages.${system}.nvim
|
2023-11-11 23:07:53 +01:00
|
|
|
htop-vim
|
2024-03-16 15:27:40 +01:00
|
|
|
nvim
|
2023-11-12 17:58:32 +01:00
|
|
|
pciutils
|
2023-10-01 16:03:02 +02:00
|
|
|
tig
|
2023-11-12 17:58:32 +01:00
|
|
|
tmux
|
2023-10-01 16:03:02 +02:00
|
|
|
unzip
|
2023-11-12 17:58:32 +01:00
|
|
|
usbutils
|
2023-10-01 16:03:02 +02:00
|
|
|
wget
|
|
|
|
zip
|
|
|
|
];
|
|
|
|
|
2023-10-20 21:41:23 +02:00
|
|
|
programs.mosh.enable = true;
|
|
|
|
|
2023-10-01 16:03:02 +02:00
|
|
|
mailserver = {
|
|
|
|
enable = true;
|
|
|
|
debug = false;
|
|
|
|
fqdn = "mail.project-cloud.net";
|
2025-01-10 18:11:42 +01:00
|
|
|
domains = [ "project-cloud.net" ];
|
2023-10-25 20:56:34 +02:00
|
|
|
enableSubmissionSsl = true;
|
2023-10-01 16:03:02 +02:00
|
|
|
enableImap = false;
|
2023-10-25 20:56:34 +02:00
|
|
|
enableImapSsl = true;
|
2023-10-01 16:03:02 +02:00
|
|
|
|
|
|
|
# A list of all login accounts. To create the password hashes, use
|
|
|
|
# nix-shell -p mkpasswd --run 'mkpasswd -sm bcrypt'
|
|
|
|
loginAccounts = {
|
|
|
|
"gitea@project-cloud.net" = {
|
2023-10-14 23:24:16 +02:00
|
|
|
hashedPasswordFile = config.sops.secrets."gitea_mail_pw_hash".path;
|
2025-01-10 18:11:42 +01:00
|
|
|
aliases = [ "git@project-cloud.net" ];
|
2023-10-01 16:03:02 +02:00
|
|
|
};
|
2023-10-20 21:10:56 +02:00
|
|
|
"asmir@project-cloud.net" = {
|
|
|
|
hashedPasswordFile = config.sops.secrets."asmir_mail_pw_hash".path;
|
2025-01-10 18:11:42 +01:00
|
|
|
aliases = [ "asmir.abdulahovic@project-cloud.net" ];
|
2023-10-20 21:10:56 +02:00
|
|
|
};
|
2023-10-01 16:03:02 +02:00
|
|
|
};
|
2023-10-17 22:51:43 +02:00
|
|
|
certificateScheme = "acme-nginx";
|
2023-10-01 16:03:02 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
services.journald.extraConfig = ''SystemMaxUse=50M '';
|
|
|
|
services.logind.extraConfig = ''KillUserProcesses=yes '';
|
|
|
|
services.openssh.settings.PermitRootLogin = "prohibit-password";
|
|
|
|
services.openssh.enable = true;
|
2024-04-04 22:48:21 +02:00
|
|
|
services.openssh.listenAddresses = [
|
|
|
|
{
|
|
|
|
addr = "10.100.0.1"; # wireguard
|
|
|
|
port = 22;
|
|
|
|
}
|
|
|
|
];
|
2023-10-01 16:03:02 +02:00
|
|
|
services.opendkim.enable = true;
|
2023-10-13 13:29:25 +02:00
|
|
|
|
|
|
|
services.miniflux = {
|
2023-11-12 19:32:23 +01:00
|
|
|
enable = false;
|
2023-10-14 23:19:24 +02:00
|
|
|
adminCredentialsFile = config.sops.secrets."miniflux_env".path;
|
|
|
|
config = {
|
|
|
|
LISTEN_ADDR = "localhost:5001";
|
|
|
|
BASE_URL = "https://miniflux.project-cloud.net";
|
|
|
|
};
|
2023-10-13 13:29:25 +02:00
|
|
|
};
|
2023-10-17 22:41:22 +02:00
|
|
|
|
2024-01-21 14:05:17 +01:00
|
|
|
services.goatcounter = {
|
|
|
|
enable = true;
|
2024-09-02 22:57:53 +02:00
|
|
|
port = 8002;
|
|
|
|
proxy = true;
|
|
|
|
address = "127.0.0.1";
|
2024-01-21 14:05:17 +01:00
|
|
|
};
|
|
|
|
|
2023-11-06 19:25:49 +01:00
|
|
|
services.nextcloud = {
|
2024-07-06 21:07:51 +02:00
|
|
|
enable = false;
|
2024-03-30 19:50:12 +01:00
|
|
|
package = pkgs.nextcloud28;
|
2023-10-20 21:35:43 +02:00
|
|
|
config.adminpassFile = config.sops.secrets."nextcloud_admin".path;
|
|
|
|
configureRedis = true;
|
2023-11-14 14:42:20 +01:00
|
|
|
hostName = "cloud.project-cloud.net";
|
2023-10-01 16:03:02 +02:00
|
|
|
https = true;
|
2024-03-30 20:01:52 +01:00
|
|
|
settings = {
|
2023-10-20 21:35:43 +02:00
|
|
|
mail_smtpmode = "sendmail";
|
|
|
|
mail_sendmailmode = "pipe";
|
|
|
|
enabledPreviewProviders = [
|
|
|
|
"OC\\Preview\\BMP"
|
|
|
|
"OC\\Preview\\GIF"
|
|
|
|
"OC\\Preview\\HEIC"
|
|
|
|
"OC\\Preview\\JPEG"
|
|
|
|
"OC\\Preview\\Krita"
|
|
|
|
"OC\\Preview\\MarkDown"
|
|
|
|
"OC\\Preview\\MP3"
|
|
|
|
"OC\\Preview\\OpenDocument"
|
|
|
|
"OC\\Preview\\PNG"
|
|
|
|
"OC\\Preview\\TXT"
|
|
|
|
"OC\\Preview\\XBitmap"
|
|
|
|
];
|
2023-10-01 16:03:02 +02:00
|
|
|
};
|
2023-11-06 19:25:49 +01:00
|
|
|
phpOptions = {
|
|
|
|
"opcache.jit" = "tracing";
|
|
|
|
"opcache.jit_buffer_size" = "100M";
|
|
|
|
"opcache.interned_strings_buffer" = "16";
|
|
|
|
};
|
2023-10-01 16:03:02 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
services.nginx = {
|
|
|
|
enable = true;
|
2023-10-05 18:59:43 +02:00
|
|
|
package = pkgs.nginxQuic;
|
2023-10-01 16:03:02 +02:00
|
|
|
recommendedGzipSettings = true;
|
|
|
|
recommendedOptimisation = true;
|
|
|
|
recommendedProxySettings = true;
|
|
|
|
recommendedTlsSettings = true;
|
2023-10-05 19:53:08 +02:00
|
|
|
|
2023-11-14 14:42:20 +01:00
|
|
|
virtualHosts."project-cloud.net" = {
|
|
|
|
quic = true;
|
2024-03-30 19:49:13 +01:00
|
|
|
http3 = true;
|
2023-11-14 14:42:20 +01:00
|
|
|
forceSSL = true;
|
|
|
|
enableACME = true;
|
2024-03-16 17:21:46 +01:00
|
|
|
root = "${project-cloud.packages.${system}.default}/public";
|
2023-11-14 14:42:20 +01:00
|
|
|
};
|
|
|
|
|
2024-09-02 22:59:14 +02:00
|
|
|
/*
|
2025-01-10 18:11:42 +01:00
|
|
|
virtualHosts.${config.services.nextcloud.hostName} = {
|
|
|
|
quic = true;
|
|
|
|
http3 = true;
|
|
|
|
forceSSL = true;
|
|
|
|
enableACME = true;
|
|
|
|
};
|
2024-09-02 22:59:14 +02:00
|
|
|
*/
|
2023-10-05 19:53:08 +02:00
|
|
|
|
2023-10-13 13:29:25 +02:00
|
|
|
virtualHosts."miniflux.project-cloud.net" = {
|
|
|
|
quic = true;
|
2024-03-30 19:49:13 +01:00
|
|
|
http3 = true;
|
2023-10-13 13:29:25 +02:00
|
|
|
forceSSL = true;
|
|
|
|
enableACME = true;
|
|
|
|
locations."/" = {
|
|
|
|
proxyPass = "http://localhost:5001";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2023-10-05 19:04:23 +02:00
|
|
|
virtualHosts.${config.services.gitea.settings.server.DOMAIN} = {
|
2023-10-05 18:59:43 +02:00
|
|
|
quic = true;
|
2024-03-30 19:49:13 +01:00
|
|
|
http3 = true;
|
2023-10-01 16:03:02 +02:00
|
|
|
forceSSL = true;
|
|
|
|
enableACME = true;
|
|
|
|
locations."/" = {
|
2024-12-03 16:02:53 +01:00
|
|
|
proxyPass = "http://unix:${toString config.services.gitea.settings.server.HTTP_ADDR}";
|
2023-10-01 16:03:02 +02:00
|
|
|
};
|
|
|
|
};
|
2023-10-05 19:53:08 +02:00
|
|
|
|
2024-01-21 14:05:17 +01:00
|
|
|
virtualHosts."stats.project-cloud.net" = {
|
|
|
|
quic = true;
|
2024-03-30 19:49:13 +01:00
|
|
|
http3 = true;
|
2024-01-21 14:05:17 +01:00
|
|
|
forceSSL = true;
|
|
|
|
enableACME = true;
|
|
|
|
locations."/" = {
|
|
|
|
proxyPass = "http://localhost:8002/";
|
|
|
|
};
|
|
|
|
};
|
2023-10-01 16:03:02 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
services.gitea = {
|
|
|
|
enable = true;
|
|
|
|
appName = "Project Cloud Gitea server";
|
|
|
|
database = {
|
2023-10-17 23:51:20 +02:00
|
|
|
type = "sqlite3";
|
|
|
|
passwordFile = config.sops.secrets."gitea_db".path;
|
2023-10-01 16:03:02 +02:00
|
|
|
};
|
2023-10-17 22:41:22 +02:00
|
|
|
settings.server = {
|
|
|
|
DOMAIN = "git.project-cloud.net";
|
|
|
|
ROOT_URL = "https://git.project-cloud.net";
|
2023-10-17 23:14:06 +02:00
|
|
|
DISABLE_SSH = true;
|
2023-10-17 22:41:22 +02:00
|
|
|
HTTP_PORT = 3001;
|
2023-11-12 19:18:17 +01:00
|
|
|
LANDING_PAGE = "explore";
|
2024-12-03 16:02:53 +01:00
|
|
|
PROTOCOL = "http+unix";
|
2023-10-17 22:41:22 +02:00
|
|
|
};
|
|
|
|
settings.mailer = {
|
|
|
|
ENABLED = true;
|
|
|
|
FROM = "gitea@project-cloud.net";
|
|
|
|
PROTOCOL = "sendmail";
|
|
|
|
SENDMAIL_PATH = "/run/wrappers/bin/sendmail";
|
|
|
|
};
|
2023-10-17 22:50:31 +02:00
|
|
|
|
|
|
|
settings.service = {
|
2023-10-17 23:14:06 +02:00
|
|
|
DISABLE_REGISTRATION = true;
|
2023-11-12 17:43:02 +01:00
|
|
|
REGISTER_EMAIL_CONFIRM = true;
|
2023-10-17 22:50:31 +02:00
|
|
|
};
|
|
|
|
|
2025-01-10 18:11:42 +01:00
|
|
|
settings."markup.restructuredtext" =
|
|
|
|
let
|
|
|
|
docutils = pkgs.python3.withPackages (
|
|
|
|
ps: with ps; [
|
|
|
|
docutils
|
|
|
|
pygments
|
|
|
|
]
|
|
|
|
);
|
|
|
|
in
|
|
|
|
{
|
|
|
|
ENABLED = true;
|
|
|
|
FILE_EXTENSIONS = ".rst";
|
|
|
|
RENDER_COMMAND = "${docutils}/bin/rst2html.py";
|
|
|
|
IS_INPUT_FILE = false;
|
|
|
|
};
|
2023-10-01 16:03:02 +02:00
|
|
|
};
|
|
|
|
|
2024-04-17 22:28:19 +02:00
|
|
|
services.nfs.server.enable = false;
|
2024-04-05 23:03:49 +02:00
|
|
|
services.nfs.server.extraNfsdConfig = ''
|
|
|
|
rdma = true
|
|
|
|
vers3 = false
|
|
|
|
vers4.0 = false
|
|
|
|
vers4.1 = false
|
|
|
|
'';
|
|
|
|
services.nfs.server.exports = ''
|
|
|
|
/export/nixy 10.100.0.1/24(rw,nohide,insecure,no_subtree_check,all_squash,anonuid=1000,anongid=100)
|
|
|
|
'';
|
|
|
|
|
2024-04-05 23:03:01 +02:00
|
|
|
services.borgbackup.jobs."borgbase" = {
|
|
|
|
paths = [
|
|
|
|
"/var/lib/gitea"
|
|
|
|
];
|
2025-01-10 18:11:42 +01:00
|
|
|
exclude = [ ];
|
2024-04-05 23:03:01 +02:00
|
|
|
repo = "ssh://na9fqv67@na9fqv67.repo.borgbase.com/./repo";
|
|
|
|
encryption = {
|
|
|
|
mode = "repokey-blake2";
|
|
|
|
passCommand = "${pkgs.coreutils-full}/bin/cat ${config.sops.secrets."borgbase_enc_key".path}";
|
|
|
|
};
|
|
|
|
environment.BORG_RSH = "${pkgs.openssh}/bin/ssh -i ${config.sops.secrets."borgbase_ssh_key".path}";
|
|
|
|
compression = "auto,zstd";
|
|
|
|
startAt = "daily";
|
|
|
|
};
|
|
|
|
|
2024-05-15 11:37:45 +02:00
|
|
|
services.seafile = {
|
2024-07-06 21:07:51 +02:00
|
|
|
enable = false;
|
2024-05-15 11:37:45 +02:00
|
|
|
initialAdminPassword = "admin";
|
|
|
|
adminEmail = "asmir.abdulahovic" + "@" + "gmail.com";
|
|
|
|
};
|
|
|
|
|
2025-01-10 18:11:42 +01:00
|
|
|
# needed for sendmail mail functionality
|
|
|
|
users.users.gitea.extraGroups = [ "postdrop" ];
|
2023-10-17 22:41:22 +02:00
|
|
|
systemd.services.gitea.serviceConfig = {
|
2025-01-10 18:11:42 +01:00
|
|
|
RestrictAddressFamilies = [ "AF_NETLINK" ];
|
2023-10-17 22:41:22 +02:00
|
|
|
ProtectSystem = lib.mkForce false;
|
|
|
|
};
|
|
|
|
|
2023-10-01 16:03:02 +02:00
|
|
|
security.acme = {
|
|
|
|
acceptTerms = true;
|
|
|
|
defaults.email = "asmir.abdulahovic@gmail.com";
|
|
|
|
};
|
|
|
|
|
2024-04-22 20:17:39 +02:00
|
|
|
sops = {
|
2025-01-10 18:11:42 +01:00
|
|
|
age.sshKeyPaths = [ "/etc/ssh/ssh_host_ed25519_key" ];
|
2024-04-22 20:17:39 +02:00
|
|
|
secrets = {
|
|
|
|
"asmir_mail_pw_hash".sopsFile = ./secrets/asmir_mail_pw_hash.yaml;
|
|
|
|
"borgbase_enc_key".sopsFile = ./secrets/borgbase_enc_key.yaml;
|
|
|
|
"borgbase_ssh_key".sopsFile = ./secrets/borgbase_ssh_key.yaml;
|
|
|
|
"gitea_mail_pw_hash".sopsFile = ./secrets/gitea_mail_pw_hash.yaml;
|
|
|
|
"miniflux_env".sopsFile = ./secrets/miniflux.yaml;
|
|
|
|
"wg_preshared/mediabox".sopsFile = ../common/secrets/wg_preshared.yaml;
|
|
|
|
"wg_preshared/nixy".sopsFile = ../common/secrets/wg_preshared.yaml;
|
|
|
|
"wg_preshared/workstation".sopsFile = ../common/secrets/wg_preshared.yaml;
|
|
|
|
"wg_privkey".sopsFile = ./secrets/wg_privkey.yaml;
|
|
|
|
"gitea_db" = {
|
|
|
|
sopsFile = ./secrets/gitea_db.yaml;
|
|
|
|
owner = config.users.users.gitea.name;
|
|
|
|
};
|
2024-09-02 22:59:14 +02:00
|
|
|
/*
|
2025-01-10 18:11:42 +01:00
|
|
|
"nextcloud_admin" = {
|
|
|
|
sopsFile = ./secrets/nextcloud_admin.yaml;
|
|
|
|
owner = config.users.users.nextcloud.name;
|
|
|
|
};
|
2024-09-02 22:59:14 +02:00
|
|
|
*/
|
2024-04-22 20:17:39 +02:00
|
|
|
};
|
2024-04-05 23:03:01 +02:00
|
|
|
};
|
|
|
|
|
2024-04-04 21:58:53 +02:00
|
|
|
networking.hostName = "magpie";
|
|
|
|
|
2023-10-17 22:41:22 +02:00
|
|
|
networking.firewall.enable = true;
|
2025-01-10 18:11:42 +01:00
|
|
|
networking.firewall.allowedTCPPorts = [
|
|
|
|
80
|
|
|
|
443
|
|
|
|
587
|
|
|
|
2049
|
|
|
|
]; # http, mail, mail, nfs
|
|
|
|
networking.firewall.allowedUDPPorts = [
|
|
|
|
443
|
|
|
|
51820
|
|
|
|
]; # mail, wireguard
|
2023-11-06 19:23:11 +01:00
|
|
|
networking.firewall.allowPing = true;
|
|
|
|
networking.firewall.logRefusedConnections = lib.mkDefault false;
|
2024-04-04 21:58:53 +02:00
|
|
|
|
|
|
|
networking.nat.enable = true;
|
|
|
|
networking.nat.externalInterface = "enp1s0";
|
2025-01-10 18:11:42 +01:00
|
|
|
networking.nat.internalInterfaces = [ "wg0" ];
|
2024-04-04 21:58:53 +02:00
|
|
|
|
2023-10-01 16:03:02 +02:00
|
|
|
networking.networkmanager.enable = true;
|
2023-11-06 19:23:11 +01:00
|
|
|
networking.wireless.enable = false;
|
2023-10-01 16:03:02 +02:00
|
|
|
|
2024-04-04 21:58:53 +02:00
|
|
|
networking.wireguard.interfaces = {
|
|
|
|
wg0 = {
|
2025-01-10 18:11:42 +01:00
|
|
|
ips = [ "10.100.0.1/24" ];
|
2024-04-04 21:58:53 +02:00
|
|
|
listenPort = 51820;
|
|
|
|
|
|
|
|
# This allows the wireguard server to route your traffic to the internet and hence be like a VPN
|
|
|
|
# For this to work you have to set the dnsserver IP of your router (or dnsserver of choice) in your clients
|
|
|
|
postSetup = ''
|
|
|
|
${pkgs.iptables}/bin/iptables -t nat -A POSTROUTING -s 10.100.0.0/24 -o eth0 -j MASQUERADE
|
|
|
|
'';
|
|
|
|
# This undoes the above command
|
|
|
|
postShutdown = ''
|
|
|
|
${pkgs.iptables}/bin/iptables -t nat -D POSTROUTING -s 10.100.0.0/24 -o eth0 -j MASQUERADE
|
|
|
|
'';
|
|
|
|
privateKeyFile = config.sops.secrets."wg_privkey".path;
|
|
|
|
|
|
|
|
peers = [
|
|
|
|
{
|
|
|
|
publicKey = builtins.readFile ../nixy/wg_pubkey;
|
2024-04-20 20:44:36 +02:00
|
|
|
presharedKeyFile = config.sops.secrets."wg_preshared/nixy".path;
|
2025-01-10 18:11:42 +01:00
|
|
|
allowedIPs = [ "10.100.0.6/32" ];
|
2024-04-04 21:58:53 +02:00
|
|
|
}
|
2024-04-09 14:52:04 +02:00
|
|
|
{
|
|
|
|
publicKey = builtins.readFile ../mediabox/wg_pubkey;
|
2024-04-20 20:44:36 +02:00
|
|
|
presharedKeyFile = config.sops.secrets."wg_preshared/mediabox".path;
|
2025-01-10 18:11:42 +01:00
|
|
|
allowedIPs = [ "10.100.0.5/32" ];
|
2024-04-09 14:52:04 +02:00
|
|
|
}
|
2024-04-22 18:10:24 +02:00
|
|
|
{
|
|
|
|
publicKey = builtins.readFile ../common/wg_pubkey_workstation;
|
|
|
|
presharedKeyFile = config.sops.secrets."wg_preshared/workstation".path;
|
2025-01-10 18:11:42 +01:00
|
|
|
allowedIPs = [ "10.100.0.4/32" ];
|
2024-04-22 18:10:24 +02:00
|
|
|
}
|
2024-04-04 21:58:53 +02:00
|
|
|
];
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2023-11-06 22:16:41 +01:00
|
|
|
systemd = {
|
|
|
|
enableEmergencyMode = false;
|
|
|
|
|
|
|
|
watchdog = {
|
|
|
|
runtimeTime = "20s";
|
|
|
|
rebootTime = "30s";
|
|
|
|
};
|
|
|
|
|
|
|
|
sleep.extraConfig = ''
|
|
|
|
AllowSuspend=no
|
|
|
|
AllowHibernation=no
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2023-10-01 16:03:02 +02:00
|
|
|
system.stateVersion = "22.11";
|
|
|
|
}
|