Configure tailscale
This commit is contained in:
parent
9032afaf5a
commit
c16463dd65
21
flake.lock
generated
21
flake.lock
generated
@ -1,5 +1,25 @@
|
||||
{
|
||||
"nodes": {
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixpkgs-unstable"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1705335923,
|
||||
"narHash": "sha256-jRyp+a89Y7Cb2V/NyIJpgu5gsND419bY16omCZWy+jc=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "b989db5900df4bd1a786f8afd8063dae09d89a8c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1705183652,
|
||||
@ -32,6 +52,7 @@
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"home-manager": "home-manager",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nixpkgs-unstable": "nixpkgs-unstable"
|
||||
}
|
||||
|
23
flake.nix
23
flake.nix
@ -3,30 +3,37 @@
|
||||
|
||||
|
||||
inputs = {
|
||||
# Stable
|
||||
nixpkgs.url = "nixpkgs/nixos-23.11";
|
||||
|
||||
# Unstable
|
||||
nixpkgs-unstable.url = "nixpkgs/nixos-unstable";
|
||||
home-manager.url = "github:nix-community/home-manager";
|
||||
home-manager.inputs.nixpkgs.follows = "nixpkgs-unstable";
|
||||
};
|
||||
|
||||
|
||||
outputs = { self, nixpkgs, nixpkgs-unstable }: {
|
||||
outputs = { self, nixpkgs, nixpkgs-unstable, home-manager }:
|
||||
let common_dir = ./common;
|
||||
in {
|
||||
nixosConfigurations = {
|
||||
|
||||
nixos = nixpkgs-unstable.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = {
|
||||
inherit self;
|
||||
nixpkgs = nixpkgs-unstable;
|
||||
};
|
||||
specialArgs = { inherit common_dir; };
|
||||
modules = [
|
||||
./hosts/nixos/configuration.nix
|
||||
home-manager.nixosModules.home-manager {
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
# home-manager.users.cameron = import ./hosts/nixos/home-manager/cameron.nix;
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
nixserver = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = {
|
||||
inherit self nixpkgs;
|
||||
};
|
||||
specialArgs = { inherit common_dir; };
|
||||
modules = [
|
||||
./hosts/nixserver/configuration.nix
|
||||
];
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ config, pkgs, lib, ... }:
|
||||
{ config, pkgs, lib, common_dir, ... }:
|
||||
|
||||
let common_dir=../../common;
|
||||
in {
|
||||
{
|
||||
imports = [
|
||||
# Include the results of the hardware scan.
|
||||
./hardware-configuration.nix
|
||||
@ -134,6 +133,14 @@ in {
|
||||
nssmdns4 = true;
|
||||
};
|
||||
|
||||
services.tailscale = {
|
||||
enable = true;
|
||||
openFirewall = true;
|
||||
extraUpFlags = [
|
||||
"--login-server=https://scale.cam123.dev:443"
|
||||
];
|
||||
};
|
||||
|
||||
|
||||
|
||||
# Time Configuration
|
||||
|
@ -34,6 +34,14 @@ in {
|
||||
networking.hostName = "nixserver";
|
||||
networking.networkmanager.enable = true;
|
||||
|
||||
services.tailscale = {
|
||||
enable = true;
|
||||
openFirewall = true;
|
||||
extraUpFlags = [
|
||||
"--login-server=https://scale.cam123.dev:443"
|
||||
];
|
||||
};
|
||||
|
||||
|
||||
# Set your time zone.
|
||||
time.timeZone = "America/Denver";
|
||||
|
Loading…
Reference in New Issue
Block a user