1
0
Files
configuration
flake
hosts
lib
modules
pkgs
profiles
common
common-dns
common-networking
default.nix
cybercluster-vm
dn42-router
fem-net
hetzner-cloud
mercury-vm
netcup
network-fallback-dhcp
serial-console
wg-clerie
default.nix
users
.gitignore
README.md
flake.lock
flake.nix
nixfiles/profiles/common-networking/default.nix

25 lines
532 B
Nix

{ config, lib, ... }:
with lib;
{
options.profiles.clerie.common-networking = {
enable = mkEnableOption "Common networking config";
};
config = mkIf config.profiles.clerie.common-networking.enable {
# Disable scripted network
networking.useDHCP = false;
# Enable systemd-networkd
systemd.network.enable = true;
# Don't wait for online, if NetworkManger is running too
systemd.network.wait-online = mkIf (config.networking.networkmanager.enable == true) {
enable = false;
};
};
}