From 73ae7788b96852b221989aaf0206d8fc4bad35d2 Mon Sep 17 00:00:00 2001 From: Daniel Barlow Date: Sun, 14 Jul 2024 11:53:45 +0100 Subject: [PATCH] rename wwan-related modules/services we only currently support huawei e3372/cdc ncm so let's make that explicit in the naming --- examples/l2tp.nix | 4 ++-- modules/{cdc-ncm => wwan}/default.nix | 4 ++-- modules/{cdc-ncm/wwan.nix => wwan/huawei-e3372.nix} | 0 3 files changed, 4 insertions(+), 4 deletions(-) rename modules/{cdc-ncm => wwan}/default.nix (83%) rename modules/{cdc-ncm/wwan.nix => wwan/huawei-e3372.nix} (100%) diff --git a/examples/l2tp.nix b/examples/l2tp.nix index 599ba7f..f35f1f8 100644 --- a/examples/l2tp.nix +++ b/examples/l2tp.nix @@ -39,7 +39,7 @@ in rec { }; imports = [ - ../modules/cdc-ncm + ../modules/wwan ../modules/network ../modules/vlan ../modules/ssh @@ -50,7 +50,7 @@ in rec { ]; hostname = "thing"; - services.wwan = svc.wwan.build { + services.wwan = svc.wwan.huawei-e3372.build { apn = "data.uk"; username = "user"; password = "one2one"; diff --git a/modules/cdc-ncm/default.nix b/modules/wwan/default.nix similarity index 83% rename from modules/cdc-ncm/default.nix rename to modules/wwan/default.nix index 7ba8264..bd1f794 100644 --- a/modules/cdc-ncm/default.nix +++ b/modules/wwan/default.nix @@ -8,7 +8,7 @@ in { ]; options = { - system.service.wwan = mkOption { + system.service.wwan.huawei-e3372 = mkOption { type = liminix.lib.types.serviceDefn; }; }; @@ -21,7 +21,7 @@ in { }; # https://www.0xf8.org/2017/01/flashing-a-huawei-e3372h-4g-lte-stick-from-hilink-to-stick-mode/ - system.service.wwan = config.system.callService ./wwan.nix { + system.service.wwan.huawei-e3372 = config.system.callService ./huawei-e3372.nix { apn = mkOption { type = types.str; }; username = mkOption { type = types.str; }; password = mkOption { type = types.str; }; diff --git a/modules/cdc-ncm/wwan.nix b/modules/wwan/huawei-e3372.nix similarity index 100% rename from modules/cdc-ncm/wwan.nix rename to modules/wwan/huawei-e3372.nix