0
0
Fork 0
mirror of https://github.com/NixOS/nixpkgs.git synced 2025-07-13 21:50:33 +03:00

nixos/netbox: use netbox_3_6 for stateVersion>=23.11

This commit is contained in:
Minijackson 2023-09-24 10:07:28 +02:00
parent 3cc7cbce03
commit 828f0446f5
No known key found for this signature in database
GPG key ID: FEA888C9F5D64F62
2 changed files with 13 additions and 2 deletions

View file

@ -74,9 +74,18 @@ in {
package = lib.mkOption {
type = lib.types.package;
default = if lib.versionAtLeast config.system.stateVersion "23.05" then pkgs.netbox_3_5 else pkgs.netbox_3_3;
default =
if lib.versionAtLeast config.system.stateVersion "23.11"
then pkgs.netbox_3_6
else if lib.versionAtLeast config.system.stateVersion "23.05"
then pkgs.netbox_3_5
else pkgs.netbox_3_3;
defaultText = lib.literalExpression ''
if versionAtLeast config.system.stateVersion "23.05" then pkgs.netbox_3_5 else pkgs.netbox_3_3;
if lib.versionAtLeast config.system.stateVersion "23.11"
then pkgs.netbox_3_6
else if lib.versionAtLeast config.system.stateVersion "23.05"
then pkgs.netbox_3_5
else pkgs.netbox_3_3;
'';
description = lib.mdDoc ''
NetBox package to use.