seem to work

This commit is contained in:
Ingolf Wagner 2021-09-24 06:47:46 +02:00
parent 2345fdfe79
commit c6f9e7530c
No known key found for this signature in database
GPG key ID: 76BF5F1928B9618B
2 changed files with 14 additions and 5 deletions

View file

@ -1,6 +1,13 @@
{ writeCommand, lib, ... }: { writeCommand, lib, ... }:
let let
# command that ensures we use flake.nix during switch
command = targetPath: ''
nix-shell \
-E "with import <nixpkgs> {}; mkShell { buildInputs = [ git (nixos { nix.package = nixFlakes; }).nixos-rebuild ]; }" \
--run 'nixos-rebuild build --flake ${targetPath} -L --keep-going'
'';
secrets = name: { secrets = name: {
secrets.pass = { secrets.pass = {
dir = toString ~/.password-store; dir = toString ~/.password-store;
@ -31,6 +38,7 @@ let
#mqtt.file = toString ./mqtt; #mqtt.file = toString ./mqtt;
pkgs.file = toString ./pkgs; pkgs.file = toString ./pkgs;
system.file = toString ./system; system.file = toString ./system;
"flake.nix".file = toString ./flake.nix;
#backup-module.file = toString ~/dev/backup; #backup-module.file = toString ~/dev/backup;
backup-module.git = { backup-module.git = {
@ -57,5 +65,6 @@ in {
#source = lib.evalSource [ source (secrets "sterni") desktopSecrets ]; #source = lib.evalSource [ source (secrets "sterni") desktopSecrets ];
source = lib.evalSource [ source ]; source = lib.evalSource [ source ];
target = lib.mkTarget "root@sterni.private"; target = lib.mkTarget "root@sterni.private";
inherit command;
}; };
} }

View file

@ -1,13 +1,13 @@
{ lib, config, pkgs, ... }: { { lib, config, pkgs, ... }: {
imports = [ imports = [
<backup-module> #<backup-module>
<krops-lib> #<krops-lib>
<cluster-module> #<cluster-module>
<modules> #<modules>
# needed # needed
<home-manager/nixos> #<home-manager/nixos>
# cross-compiling # cross-compiling
#<cleverca22/qemu.nix> #<cleverca22/qemu.nix>