wireguard gateway draft added

This commit is contained in:
Lyn 2024-10-19 04:08:28 +02:00
parent dcbfb0be74
commit 7a450258d4
3 changed files with 61 additions and 4 deletions

View file

@ -35,21 +35,28 @@
modules = [
./hosts/forgenite
imports
];
];
};
"forgejo-ci" = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
./hosts/forgejo-ci
imports
];
];
};
"supernova" = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
./hosts/supernova
imports
];
imports
];
};
"wg_gateway" = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
./hosts/wg_gateway
imports
];
};
};
};

View file

@ -0,0 +1,17 @@
{ config, lib, pkgs, ... }:
{
imports =
[ # Include the results of the hardware scan.
./hardware-configuration.nix
];
boot.loader.grub.enable = true;
boot.loader.grub.device = "/dev/sda";
lyn.kernel.latest.enable = true;
lyn.kernel.hardened.enable =true;
lyn.profiles.base.enable = true;
lyn.users.lyn.enable = true;
networking.hostName = "wg_gateway"; # Define your hostname.
}

View file

@ -0,0 +1,33 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{
imports =
[ (modulesPath + "/profiles/qemu-guest.nix")
];
boot.initrd.availableKernelModules = [ "ahci" "xhci_pci" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/8585b573-d3d6-48a3-91cf-76d198ea3046";
fsType = "ext4";
};
swapDevices =
[ { device = "/dev/disk/by-uuid/0e0e9cca-0017-47aa-93f8-3231a29fd772"; }
];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault true;
# networking.interfaces.enp1s0.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
}