Compare commits
7 Commits
master
...
nixos-23.0
Author | SHA1 | Date |
---|---|---|
Astro | f076089053 | |
Astro | d7ef05fa64 | |
Astro | f55cb13ecf | |
Astro | 1caffb4f0f | |
Astro | 7cf95cd2f0 | |
Astro | 2ee8f7a5cc | |
Astro | bb7460ff83 |
|
@ -280,7 +280,7 @@
|
||||||
ap9.wifi."platform/qca953x_wmac".ssids."Herzzbuehne".psk = "encrypted";
|
ap9.wifi."platform/qca953x_wmac".ssids."Herzzbuehne".psk = "encrypted";
|
||||||
};
|
};
|
||||||
|
|
||||||
site.dyndnsKey = "SECRET";
|
site.dyndnsKey = "oYmxXCIa0nArp0679L6v+y/UfnhripOudLv+R5Cop8I=";
|
||||||
|
|
||||||
site.vpn.wireguard = {
|
site.vpn.wireguard = {
|
||||||
privateKey = "wPNXY4ED3Jz3Kz0KOmvfQOou6/wHrgqSsykaMYrtb28=";
|
privateKey = "wPNXY4ED3Jz3Kz0KOmvfQOou6/wHrgqSsykaMYrtb28=";
|
||||||
|
|
22
flake.lock
22
flake.lock
|
@ -2,16 +2,16 @@
|
||||||
"nodes": {
|
"nodes": {
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1681490924,
|
"lastModified": 1685912674,
|
||||||
"narHash": "sha256-6WrkhmG0pI09VqeYWRLxEgNlVeWdnM5at6vm0w4prBk=",
|
"narHash": "sha256-9iRV7ZxZO13MXEBZvWTak9OTddkit66qbbDtroqV4X4=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "781df3d2de37ace250ba3c2731606c0b6bee465b",
|
"rev": "18388d019974e90a035bdb938a8a3ca3c0408db9",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"ref": "release-22.11",
|
"ref": "release-23.05",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
|
@ -19,11 +19,11 @@
|
||||||
"openwrt": {
|
"openwrt": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1681412046,
|
"lastModified": 1685795498,
|
||||||
"narHash": "sha256-mW4B/9GVminuxC0EM6WeQ9soqBy2k8INjhpT+mrnIow=",
|
"narHash": "sha256-DZS2L/646UDQjXKVYL5wuqoYXQ1cc/9M7fy5lXQ5/Gw=",
|
||||||
"ref": "openwrt-22.03",
|
"ref": "openwrt-22.03",
|
||||||
"rev": "9af29da281213108cd861ed77b0416bf6eda0aaf",
|
"rev": "171b51519206b5e66ebd01d322f41d790976ce87",
|
||||||
"revCount": 54587,
|
"revCount": 54629,
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://git.openwrt.org/openwrt/openwrt.git"
|
"url": "https://git.openwrt.org/openwrt/openwrt.git"
|
||||||
},
|
},
|
||||||
|
@ -40,11 +40,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1681468707,
|
"lastModified": 1685874260,
|
||||||
"narHash": "sha256-aD+74KowPjyxWP+bIqmZZaIHe5WxEhoXOSF+qOOCwPg=",
|
"narHash": "sha256-rem5LdqVtunLJZ+lXvwAJCMFucJmT+kaXoTOIbGelXg=",
|
||||||
"owner": "astro",
|
"owner": "astro",
|
||||||
"repo": "nix-openwrt-imagebuilder",
|
"repo": "nix-openwrt-imagebuilder",
|
||||||
"rev": "b3d1f398472452ea288ce2d8dbf20d6115bf1c64",
|
"rev": "b5901ec9361152f1f588445d1b3f06239ea4b86c",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
description = "Zentralwerk network";
|
description = "Zentralwerk network";
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:NixOS/nixpkgs/release-22.11";
|
nixpkgs.url = "github:NixOS/nixpkgs/release-23.05";
|
||||||
openwrt = {
|
openwrt = {
|
||||||
url = "git+https://git.openwrt.org/openwrt/openwrt.git?ref=openwrt-22.03";
|
url = "git+https://git.openwrt.org/openwrt/openwrt.git?ref=openwrt-22.03";
|
||||||
flake = false;
|
flake = false;
|
||||||
|
|
|
@ -6,18 +6,11 @@
|
||||||
(modulesPath + "/virtualisation/lxc-container.nix")
|
(modulesPath + "/virtualisation/lxc-container.nix")
|
||||||
];
|
];
|
||||||
|
|
||||||
boot = {
|
|
||||||
isContainer = true;
|
|
||||||
loader = {
|
|
||||||
initScript.enable = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
environment.etc."machine-id".text =
|
environment.etc."machine-id".text =
|
||||||
builtins.substring 0 8 (
|
builtins.substring 0 8 (
|
||||||
builtins.hashString "sha256" config.networking.hostName
|
builtins.hashString "sha256" config.networking.hostName
|
||||||
);
|
);
|
||||||
|
|
||||||
nix = {
|
nix = {
|
||||||
settings = {
|
settings = {
|
||||||
sandbox = false;
|
sandbox = false;
|
||||||
|
|
|
@ -26,7 +26,7 @@ in lib.mkIf (pppoeInterfaces != {}) {
|
||||||
enable = true;
|
enable = true;
|
||||||
autostart = true;
|
autostart = true;
|
||||||
config = ''
|
config = ''
|
||||||
plugin rp-pppoe.so
|
plugin pppoe.so
|
||||||
nic-${upstream.link}
|
nic-${upstream.link}
|
||||||
ifname ${ifName}
|
ifname ${ifName}
|
||||||
# Login settings. (PAP)
|
# Login settings. (PAP)
|
||||||
|
@ -39,11 +39,11 @@ in lib.mkIf (pppoeInterfaces != {}) {
|
||||||
maxfail 0
|
maxfail 0
|
||||||
# Seconds between reconnection attempts
|
# Seconds between reconnection attempts
|
||||||
holdoff 1
|
holdoff 1
|
||||||
|
|
||||||
# LCP settings.
|
# LCP settings.
|
||||||
lcp-echo-interval 5
|
lcp-echo-interval 5
|
||||||
lcp-echo-failure 6
|
lcp-echo-failure 6
|
||||||
|
|
||||||
# PPPoE compliant settings.
|
# PPPoE compliant settings.
|
||||||
noaccomp
|
noaccomp
|
||||||
default-asyncmap
|
default-asyncmap
|
||||||
|
|
|
@ -7,9 +7,9 @@
|
||||||
# Prevents automatic creation of interface bond0 by the kernel
|
# Prevents automatic creation of interface bond0 by the kernel
|
||||||
"bonding.max_bonds=0"
|
"bonding.max_bonds=0"
|
||||||
];
|
];
|
||||||
boot.tmpOnTmpfs = true;
|
boot.tmp.useTmpfs = true;
|
||||||
# Includes wireguard
|
# Includes wireguard
|
||||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
boot.kernelPackages = pkgs.zfsUnstable.latestCompatibleLinuxPackages;
|
||||||
# Keep building
|
# Keep building
|
||||||
boot.zfs.enableUnstable = true;
|
boot.zfs.enableUnstable = true;
|
||||||
|
|
||||||
|
@ -35,8 +35,8 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
documentation = {
|
documentation = {
|
||||||
enable = false;
|
enable = lib.mkForce false;
|
||||||
nixos.enable = false;
|
nixos.enable = lib.mkForce false;
|
||||||
};
|
};
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
|
|
|
@ -12,7 +12,7 @@
|
||||||
ipmitool
|
ipmitool
|
||||||
];
|
];
|
||||||
services.openssh.enable = true;
|
services.openssh.enable = true;
|
||||||
services.openssh.permitRootLogin = "prohibit-password";
|
services.openssh.settings.PermitRootLogin = "prohibit-password";
|
||||||
|
|
||||||
# additional config for bare metal
|
# additional config for bare metal
|
||||||
services.collectd = {
|
services.collectd = {
|
||||||
|
|
|
@ -14,6 +14,10 @@ let
|
||||||
shortenNetName = name:
|
shortenNetName = name:
|
||||||
if builtins.match "priv(.*)" name != null
|
if builtins.match "priv(.*)" name != null
|
||||||
then "p" + builtins.substring 4 9 name
|
then "p" + builtins.substring 4 9 name
|
||||||
|
else if name == "coloradio"
|
||||||
|
then "cr"
|
||||||
|
else if name == "coloradio-gw"
|
||||||
|
then "cr-gw"
|
||||||
else name;
|
else name;
|
||||||
|
|
||||||
checkIfname = ifname: let
|
checkIfname = ifname: let
|
||||||
|
@ -248,6 +252,8 @@ in
|
||||||
Restart = "always";
|
Restart = "always";
|
||||||
RestartSec = "1s";
|
RestartSec = "1s";
|
||||||
};
|
};
|
||||||
|
# Prevent restart on host nixos-rebuild switch
|
||||||
|
restartIfChanged = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
# Starts all the containers after boot
|
# Starts all the containers after boot
|
||||||
|
|
Loading…
Reference in New Issue