2022-06-12 04:59:12 +00:00
|
|
|
{ lib, config, ... }:
|
|
|
|
|
|
|
|
|
|
let
|
|
|
|
|
cfg = config.greg.tailscale;
|
|
|
|
|
in {
|
|
|
|
|
options = {
|
|
|
|
|
greg.tailscale.enable = lib.mkEnableOption "Enable Tailscale";
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
config = lib.mkIf cfg.enable {
|
|
|
|
|
services.tailscale.enable = true;
|
|
|
|
|
networking.firewall.checkReversePath = "loose";
|
2023-04-18 05:17:33 +00:00
|
|
|
boot.kernel.sysctl = {
|
|
|
|
|
"net.ipv4.ip_forward" = "1";
|
|
|
|
|
"net.ipv6.conf.all.forwarding" = "1";
|
|
|
|
|
};
|
2022-06-12 04:59:12 +00:00
|
|
|
};
|
|
|
|
|
}
|