feature(toxvpn): add initial commit
This commit is contained in:
parent
9c3858318a
commit
c3ce25c827
|
@ -5125,16 +5125,16 @@
|
||||||
},
|
},
|
||||||
"nixpkgsUnstable": {
|
"nixpkgsUnstable": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1727122398,
|
"lastModified": 1727561184,
|
||||||
"narHash": "sha256-o8VBeCWHBxGd4kVMceIayf5GApqTavJbTa44Xcg5Rrk=",
|
"narHash": "sha256-mVR5o+9xEs8EJqNXQDeXq6v3KlcSAKsB2L2z4rNRjZY=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "30439d93eb8b19861ccbe3e581abf97bdc91b093",
|
"rev": "60c3d109ffe080e672f14047c1e7a24896f06186",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"ref": "nixos-unstable",
|
"ref": "pull/345190/head",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,7 +12,7 @@
|
||||||
iohkNix.url = github:input-output-hk/iohk-nix/?ref=df1da282f996ec46b33379407df99613a1fbafdd;
|
iohkNix.url = github:input-output-hk/iohk-nix/?ref=df1da282f996ec46b33379407df99613a1fbafdd;
|
||||||
nix.url = github:NixOS/nix/?ref=2.24.6;
|
nix.url = github:NixOS/nix/?ref=2.24.6;
|
||||||
nixpkgs.url = github:NixOS/nixpkgs/?ref=nixos-24.05;
|
nixpkgs.url = github:NixOS/nixpkgs/?ref=nixos-24.05;
|
||||||
nixpkgsUnstable.url = github:NixOS/nixpkgs/?ref=nixos-unstable;
|
nixpkgsUnstable.url = github:NixOS/nixpkgs/?ref=pull/345190/head;
|
||||||
ragenix = {
|
ragenix = {
|
||||||
url = github:yaxitech/ragenix;
|
url = github:yaxitech/ragenix;
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
../../profiles/ipv6.nix
|
../../profiles/ipv6.nix
|
||||||
../../profiles/mastodon.nix
|
../../profiles/mastodon.nix
|
||||||
../../profiles/matrix.nix
|
../../profiles/matrix.nix
|
||||||
#../../profiles/mcwhirter.io.nix
|
../../profiles/mcwhirter.io.nix
|
||||||
#../../profiles/minecraftServer.nix
|
#../../profiles/minecraftServer.nix
|
||||||
../../profiles/nextcloud.nix
|
../../profiles/nextcloud.nix
|
||||||
../../profiles/nixpkgs-dev.nix
|
../../profiles/nixpkgs-dev.nix
|
||||||
|
|
|
@ -21,8 +21,6 @@
|
||||||
../../profiles/users-ops.nix # MIO Ops users
|
../../profiles/users-ops.nix # MIO Ops users
|
||||||
];
|
];
|
||||||
|
|
||||||
deployment.targetHost = "10.42.0.11";
|
|
||||||
|
|
||||||
nixpkgs = {
|
nixpkgs = {
|
||||||
config = {
|
config = {
|
||||||
allowUnfree = true;
|
allowUnfree = true;
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
[
|
[
|
||||||
./profiles/cosmicDesktop
|
./profiles/cosmicDesktop
|
||||||
./profiles/starship
|
./profiles/starship
|
||||||
|
./profiles/toxvpn
|
||||||
./roles/desktop
|
./roles/desktop
|
||||||
./roles/desktopCraige
|
./roles/desktopCraige
|
||||||
]
|
]
|
||||||
|
|
23
modules/profiles/toxvpn/default.nix
Normal file
23
modules/profiles/toxvpn/default.nix
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
# VPN configuration for MIO.
|
||||||
|
{
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
with lib; let
|
||||||
|
cfg = config.profiles.toxvpn;
|
||||||
|
in {
|
||||||
|
options.profiles.toxvpn = {
|
||||||
|
enable = mkEnableOption "to enable toxvpn.";
|
||||||
|
};
|
||||||
|
config = mkIf (cfg.enable) {
|
||||||
|
services.toxvpn = {
|
||||||
|
enable = true;
|
||||||
|
auto_add_peers = [
|
||||||
|
"4b921c107cd25b9bc62dfa4a040a9409f51d3aa001d4f12e15f01b4eba9e2f7f8ecc3b68cd13" # sanganto
|
||||||
|
"a18dfff426f5a752eb1bdc90ea307850982c1dff1444caf72b75f73483e358213b60281235a4" # eamhair
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -23,6 +23,7 @@ in {
|
||||||
libreoffice-fresh # Comprehensive, professional-quality productivity suite
|
libreoffice-fresh # Comprehensive, professional-quality productivity suite
|
||||||
mplayer # A movie player that supports many video formats
|
mplayer # A movie player that supports many video formats
|
||||||
nextcloud-client # Nextcloud desktop client
|
nextcloud-client # Nextcloud desktop client
|
||||||
|
pavucontrol # PulseAudio Volume Control
|
||||||
pwgen # Password generator
|
pwgen # Password generator
|
||||||
rsync
|
rsync
|
||||||
shotwell # Photo organizer
|
shotwell # Photo organizer
|
||||||
|
|
11
outputs.nix
11
outputs.nix
|
@ -36,14 +36,20 @@ in {
|
||||||
overlays = [];
|
overlays = [];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
defaults = {
|
defaults = {pkgs, ...}: {
|
||||||
imports = [
|
imports = [
|
||||||
./modules
|
./modules
|
||||||
cosmicDesktop.nixosModules.default
|
cosmicDesktop.nixosModules.default
|
||||||
];
|
];
|
||||||
# make flake inputs accessible in NixOS
|
# make flake inputs accessible in NixOS
|
||||||
_module.args.inputs = inputs;
|
_module.args.inputs = inputs;
|
||||||
|
nixpkgs.overlays = [
|
||||||
|
(super: self: {
|
||||||
|
inherit (nixpkgsUnstable.legacyPackages."${pkgs.system}") toxvpn;
|
||||||
|
})
|
||||||
|
];
|
||||||
profiles.starship.enable = true;
|
profiles.starship.enable = true;
|
||||||
|
profiles.toxvpn.enable = true;
|
||||||
};
|
};
|
||||||
# Comment out deployment line when building the SD Image.
|
# Comment out deployment line when building the SD Image.
|
||||||
airgead = {
|
airgead = {
|
||||||
|
@ -128,6 +134,7 @@ in {
|
||||||
tags = ["active" "rPi"];
|
tags = ["active" "rPi"];
|
||||||
targetHost = "10.42.0.205";
|
targetHost = "10.42.0.205";
|
||||||
};
|
};
|
||||||
|
services.toxvpn.localip = "10.37.0.205";
|
||||||
};
|
};
|
||||||
iolear-beag = {
|
iolear-beag = {
|
||||||
imports = [
|
imports = [
|
||||||
|
@ -150,8 +157,10 @@ in {
|
||||||
hosts/sanganto
|
hosts/sanganto
|
||||||
ragenix.nixosModules.default
|
ragenix.nixosModules.default
|
||||||
];
|
];
|
||||||
|
deployment.targetHost = "10.42.0.11";
|
||||||
roles.desktop.enable = true;
|
roles.desktop.enable = true;
|
||||||
roles.desktopCraige.enable = true;
|
roles.desktopCraige.enable = true;
|
||||||
|
services.toxvpn.localip = "10.37.0.11";
|
||||||
};
|
};
|
||||||
sercanto = {
|
sercanto = {
|
||||||
imports = [
|
imports = [
|
||||||
|
|
|
@ -4,8 +4,8 @@
|
||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
sources = import ../nix/sources.nix;
|
#sources = import ../nix/sources.nix;
|
||||||
mcwhirter-io = import sources.mcwhirter-io {};
|
#mcwhirter-io = import sources.mcwhirter-io {};
|
||||||
webdomain = "mcwhirter.io";
|
webdomain = "mcwhirter.io";
|
||||||
in {
|
in {
|
||||||
environment.sessionVariables = {
|
environment.sessionVariables = {
|
||||||
|
@ -23,7 +23,7 @@ in {
|
||||||
# website hostname
|
# website hostname
|
||||||
enableACME = true; # Use ACME certs
|
enableACME = true; # Use ACME certs
|
||||||
forceSSL = true; # Force SSL
|
forceSSL = true; # Force SSL
|
||||||
root = "${mcwhirter-io}"; # Wesbite root
|
#root = "${mcwhirter-io}"; # Wesbite root
|
||||||
};
|
};
|
||||||
"www.${webdomain}" = {
|
"www.${webdomain}" = {
|
||||||
# Respect our elders :-)
|
# Respect our elders :-)
|
||||||
|
|
Loading…
Reference in a new issue