make networking more tightly controlled by config values
This commit is contained in:
parent
a24bafbb17
commit
1816d49646
@ -1,24 +1,29 @@
|
|||||||
{ pkgs, config, lib, ... }: let
|
{ pkgs, config, lib, ... }: let
|
||||||
cfg = config.grimmShared;
|
cfg = config.grimmShared;
|
||||||
in {
|
in {
|
||||||
config = with cfg; lib.mkIf (enable && network) {
|
config = with cfg; lib.mkIf (enable && network) lib.mkMerge [
|
||||||
|
{
|
||||||
networking.networkmanager.enable = true;
|
networking.networkmanager.enable = true;
|
||||||
networking.useDHCP = lib.mkDefault true;
|
networking.useDHCP = lib.mkDefault true;
|
||||||
networking.firewall.enable = true;
|
networking.firewall.enable = true;
|
||||||
|
|
||||||
services.blueman.enable = true;
|
|
||||||
hardware.bluetooth.enable = true;
|
hardware.bluetooth.enable = true;
|
||||||
|
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
wireguard-tools
|
||||||
|
bluetuith
|
||||||
|
];
|
||||||
|
}
|
||||||
|
(lib.mkIf cfg.graphical {
|
||||||
|
services.blueman.enable = true;
|
||||||
|
})
|
||||||
|
(lib.mkIf cfg.sound {
|
||||||
systemd.user.services.mpris-proxy = {
|
systemd.user.services.mpris-proxy = {
|
||||||
description = "Mpris proxy";
|
description = "Mpris proxy";
|
||||||
after = [ "network.target" "sound.target" ];
|
after = [ "network.target" "sound.target" ];
|
||||||
wantedBy = [ "default.target" ];
|
wantedBy = [ "default.target" ];
|
||||||
serviceConfig.ExecStart = "${pkgs.bluez}/bin/mpris-proxy";
|
serviceConfig.ExecStart = "${pkgs.bluez}/bin/mpris-proxy";
|
||||||
};
|
};
|
||||||
|
})
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
wireguard-tools
|
|
||||||
bluetuith
|
|
||||||
];
|
];
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
@ -53,7 +53,7 @@ in {
|
|||||||
glxinfo
|
glxinfo
|
||||||
alacritty
|
alacritty
|
||||||
vulkan-tools
|
vulkan-tools
|
||||||
pdfaranger
|
pdfarranger
|
||||||
nomacs
|
nomacs
|
||||||
gparted
|
gparted
|
||||||
];
|
];
|
||||||
|
Loading…
Reference in New Issue
Block a user