mirror of
https://github.com/TECHNOFAB11/kubenix.git
synced 2025-12-13 16:40:05 +01:00
feat(k8s): sort resources, put CustomResourceDefinition first
This commit is contained in:
parent
2f7c0385ae
commit
dd9b3c3a5b
1 changed files with 3 additions and 1 deletions
|
|
@ -176,7 +176,9 @@ in {
|
||||||
options.kubernetes.objects = mkOption {
|
options.kubernetes.objects = mkOption {
|
||||||
description = "Attribute set of kubernetes objects";
|
description = "Attribute set of kubernetes objects";
|
||||||
type = types.listOf types.attrs;
|
type = types.listOf types.attrs;
|
||||||
apply = unique;
|
apply = items: sort (r1: r2:
|
||||||
|
if r1.kind == "CustomResourceDefinition" || r2.kind == "CustomResourceDefinition" then true else false
|
||||||
|
) (moduleToAttrs (unique items));
|
||||||
default = [];
|
default = [];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue