feat: support routes

This commit is contained in:
2024-10-04 01:43:30 -04:00
parent 6b5984ac2d
commit 21d331dce6
2 changed files with 19 additions and 18 deletions

30
flake.lock generated
View File

@@ -52,11 +52,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1723685519, "lastModified": 1727977578,
"narHash": "sha256-GkXQIoZmW2zCPp1YFtAYGg/xHNyFH/Mgm79lcs81rq0=", "narHash": "sha256-DBORKcmQ7ZjA4qE1MsnF1MmZSokOGrw4W9vTCioOv2U=",
"owner": "nix-community", "owner": "nix-community",
"repo": "disko", "repo": "disko",
"rev": "276a0d055a720691912c6a34abb724e395c8e38a", "rev": "574400001b3ffe555c7a21e0ff846230759be2ed",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -70,11 +70,11 @@
"systems": "systems_2" "systems": "systems_2"
}, },
"locked": { "locked": {
"lastModified": 1710146030, "lastModified": 1726560853,
"narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", "narHash": "sha256-X6rJYSESBVr3hBoH0WbKE5KvhPU5bloyZ2L4K60/fPQ=",
"owner": "numtide", "owner": "numtide",
"repo": "flake-utils", "repo": "flake-utils",
"rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", "rev": "c1dfcf08411b08f6b8615f7d8971a2bfa81d5e8a",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -106,11 +106,11 @@
}, },
"nixlib": { "nixlib": {
"locked": { "locked": {
"lastModified": 1723337705, "lastModified": 1727571693,
"narHash": "sha256-znSU0DeNDPt7+LMAfFkvKloMaeQ6yl/U5SqV/ktl1vA=", "narHash": "sha256-b7sFVeqMtz8xntCL3tBY3O8suTg5PeF53LTL3eCcKyc=",
"owner": "nix-community", "owner": "nix-community",
"repo": "nixpkgs.lib", "repo": "nixpkgs.lib",
"rev": "ace7856d327b618d3777e31b1f224b3ab57ed71a", "rev": "bb58a3bf239e03fca9d51062e2fe028a4ea5a3d1",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -127,11 +127,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1723683171, "lastModified": 1727917377,
"narHash": "sha256-hQMQQHOVVkiCO5hmbjI3EVimWFIkRNkGIGUhyIQ0mQ0=", "narHash": "sha256-eefXdEPUMuhiV6Vy3ASSyApCseE9OoKDgL/G6qenw/4=",
"owner": "nix-community", "owner": "nix-community",
"repo": "nixos-generators", "repo": "nixos-generators",
"rev": "1cb3dc2f3af215ea40911de8fd0942c1ff3fb673", "rev": "9ae128172f823956e54947fe471bc6dfa670ecb4",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -142,11 +142,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1723703277, "lastModified": 1727969285,
"narHash": "sha256-nk0RaUB5f68BwtXAYy3WAjqFhVKqIl9Z89RGycTa2vk=", "narHash": "sha256-TbTnNocJYd0ghUFrK/lB2Ahg6M+K6l/4nMJW1X5W25g=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "8b908192e64224420e2d59dfd9b2e4309e154c5d", "rev": "75b209227dff3cbfac19f510a62f9446c92beac4",
"type": "github" "type": "github"
}, },
"original": { "original": {

View File

@@ -1,4 +1,4 @@
{ config, meta, pkgs, ... }: { config, meta, pkgs, lib, ... }:
{ {
imports = [../common/users.nix]; imports = [../common/users.nix];
nix = { nix = {
@@ -13,7 +13,8 @@
services.tailscale = { services.tailscale = {
enable = true; enable = true;
authKeyFile = config.age.secrets.tailscale.path; authKeyFile = config.age.secrets.tailscale.path;
extraUpFlags = [ "--login-server" "http://ts.yadunut.com:444" ]; useRoutingFeatures = "both";
extraUpFlags = [ "--advertise-routes=10.0.1.0/24" "--login-server=http://ts.yadunut.com:444" "--accept-routes" ];
interfaceName = "tailscale0"; interfaceName = "tailscale0";
}; };
@@ -47,7 +48,7 @@
tokenFile = config.age.secrets.k3s.path; tokenFile = config.age.secrets.k3s.path;
clusterInit = meta.hostname == "premhome-falcon-1"; clusterInit = meta.hostname == "premhome-falcon-1";
serverAddr = if meta.hostname == "premhome-falcon-1" then "" else "https://premhome-falcon-1:6444"; serverAddr = if meta.hostname == "premhome-falcon-1" then "" else "https://premhome-falcon-1:6444";
extraFlags = "--disable=servicelb --disable=traefik"; extraFlags = ["--disable=servicelb" "--disable=traefik" ];
}; };
networking.firewall.trustedInterfaces = [ "tailscale0" ]; networking.firewall.trustedInterfaces = [ "tailscale0" ];