From eb3f9e87435be5941278d819351bac0ece172051 Mon Sep 17 00:00:00 2001 From: seth Date: Thu, 20 Apr 2023 22:10:21 -0400 Subject: move to my external lib --- hosts/_turret/default.nix | 38 +++++ hosts/_turret/files/etc/config/dhcp | 55 +++++++ hosts/_turret/files/etc/config/dropbear | 5 + hosts/_turret/files/etc/config/firewall | 189 +++++++++++++++++++++++ hosts/_turret/files/etc/config/https-dns-proxy | 18 +++ hosts/_turret/files/etc/config/luci | 41 +++++ hosts/_turret/files/etc/config/network | 29 ++++ hosts/_turret/files/etc/config/rpcd | 10 ++ hosts/_turret/files/etc/config/system | 16 ++ hosts/_turret/files/etc/config/ucitrack | 56 +++++++ hosts/_turret/files/etc/config/uhttpd | 31 ++++ hosts/_turret/files/etc/config/wireless | Bin 0 -> 827 bytes hosts/_turret/files/etc/dropbear/authorized_keys | 1 + 13 files changed, 489 insertions(+) create mode 100644 hosts/_turret/default.nix create mode 100644 hosts/_turret/files/etc/config/dhcp create mode 100644 hosts/_turret/files/etc/config/dropbear create mode 100644 hosts/_turret/files/etc/config/firewall create mode 100644 hosts/_turret/files/etc/config/https-dns-proxy create mode 100644 hosts/_turret/files/etc/config/luci create mode 100644 hosts/_turret/files/etc/config/network create mode 100644 hosts/_turret/files/etc/config/rpcd create mode 100644 hosts/_turret/files/etc/config/system create mode 100644 hosts/_turret/files/etc/config/ucitrack create mode 100644 hosts/_turret/files/etc/config/uhttpd create mode 100644 hosts/_turret/files/etc/config/wireless create mode 100644 hosts/_turret/files/etc/dropbear/authorized_keys (limited to 'hosts/_turret') diff --git a/hosts/_turret/default.nix b/hosts/_turret/default.nix new file mode 100644 index 0000000..faac3d2 --- /dev/null +++ b/hosts/_turret/default.nix @@ -0,0 +1,38 @@ +{ + pkgs, + openwrt-imagebuilder, + ... +}: let + inherit (pkgs) runCommand; + inherit (pkgs.stdenv) mkDerivation; + inherit (openwrt-imagebuilder.lib) build profiles; + wrtProfiles = profiles { + inherit pkgs; + release = "22.03.3"; + }; + config = mkDerivation { + name = "openwrt-config-files"; + src = ./files; + installPhase = '' + mkdir -p $out + cp -r * $out/ + ''; + }; + image = + wrtProfiles.identifyProfile "netgear_wac104" + // { + packages = ["https-dns-proxy"]; + + files = runCommand "image-files" {} '' + mkdir -p $out/etc/uci-defaults + cat > $out/etc/uci-defaults/99-custom <