iwd: fix deprecation spam
use config.warnings instead of lib.warn
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
---
|
---
|
||||||
description = "Automatically provisions wifi credentials"
|
description = "Automatically provisions wifi credentials"
|
||||||
features = [ "inventory" ]
|
features = [ "inventory", "deprecated" ]
|
||||||
categories = [ "Network" ]
|
categories = [ "Network" ]
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|||||||
@@ -33,16 +33,6 @@ let
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
in
|
in
|
||||||
lib.warn
|
|
||||||
''
|
|
||||||
The clan module `iwd` is deprecated and replaced by the clan service `wifi`
|
|
||||||
Please migrate your config to the new service (see: https://docs.clan.lol/reference/clanServices/wifi/)
|
|
||||||
|
|
||||||
To keep passwords after migrating the config, use:
|
|
||||||
clan vars get <your-machine> iwd.<network-name>/ssid | clan vars set <your-machine> wifi.<network-name>/network-name
|
|
||||||
and:
|
|
||||||
clan vars get <your-machine> iwd.<network-name>/password | clan vars set <your-machine> wifi.<network-name>/password
|
|
||||||
''
|
|
||||||
{
|
{
|
||||||
options.clan.iwd = {
|
options.clan.iwd = {
|
||||||
networks = lib.mkOption {
|
networks = lib.mkOption {
|
||||||
@@ -90,6 +80,18 @@ lib.warn
|
|||||||
# TODO: restart the iwd.service if something changes
|
# TODO: restart the iwd.service if something changes
|
||||||
})
|
})
|
||||||
{
|
{
|
||||||
|
warnings = [
|
||||||
|
''
|
||||||
|
The clan module `iwd` is deprecated and replaced by the clan service `wifi`
|
||||||
|
Please migrate your config to the new service (see: https://docs.clan.lol/reference/clanServices/wifi/)
|
||||||
|
|
||||||
|
To keep passwords after migrating the config, use:
|
||||||
|
clan vars get <your-machine> iwd.<network-name>/ssid | clan vars set <your-machine> wifi.<network-name>/network-name
|
||||||
|
and:
|
||||||
|
clan vars get <your-machine> iwd.<network-name>/password | clan vars set <your-machine> wifi.<network-name>/password
|
||||||
|
''
|
||||||
|
];
|
||||||
|
|
||||||
# disable wpa supplicant
|
# disable wpa supplicant
|
||||||
networking.wireless.enable = false;
|
networking.wireless.enable = false;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user