mirror of
https://github.com/TECHNOFAB11/kubenix.git
synced 2025-12-12 16:10:05 +01:00
pass nixos path explicitly
This commit is contained in:
parent
7b148cd171
commit
e4493addd8
4 changed files with 15 additions and 9 deletions
|
|
@ -1,16 +1,16 @@
|
|||
{ config, pkgs, lib, kubenix, ... }:
|
||||
{ nixosPath, config, pkgs, lib, kubenix, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
cfg = config.testing;
|
||||
|
||||
nixosTesting = import <nixpkgs/nixos/lib/testing.nix> {
|
||||
nixosTesting = import "${nixosPath}/lib/testing.nix" {
|
||||
inherit pkgs;
|
||||
system = "x86_64-linux";
|
||||
};
|
||||
|
||||
kubernetesBaseConfig = { config, pkgs, lib, nodes, ... }: let
|
||||
kubernetesBaseConfig = { modulesPath, config, pkgs, lib, nodes, ... }: let
|
||||
master = findFirst
|
||||
(node: any (role: role == "master") node.config.services.kubernetes.roles)
|
||||
(throw "no master node")
|
||||
|
|
@ -23,7 +23,7 @@ let
|
|||
(attrValues nodes)}
|
||||
'';
|
||||
in {
|
||||
imports = [ <nixpkgs/nixos/modules/profiles/minimal.nix> ];
|
||||
imports = [ "${toString modulesPath}/profiles/minimal.nix" ];
|
||||
|
||||
config = mkMerge [{
|
||||
boot.postBootCommands = "rm -fr /var/lib/kubernetes/secrets /tmp/shared/*";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue