Fix sops-nix failure after reboot
/home partition of lvm wasn't mounted and sops-nix couldn't find the key in that unmounted partition
This commit is contained in:
parent
02adc74c5a
commit
0c8b4ccfa9
2 changed files with 26 additions and 28 deletions
|
@ -1,13 +1,11 @@
|
|||
{
|
||||
inputs,
|
||||
outputs,
|
||||
lib,
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
{ inputs
|
||||
, outputs
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
vars = import ../../vars.nix;
|
||||
in {
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
inputs.hardware.nixosModules.common-pc-ssd
|
||||
inputs.disko.nixosModules.default
|
||||
|
@ -40,13 +38,15 @@ in {
|
|||
systemd.services.NetworkManager-wait-online.enable = false;
|
||||
|
||||
# Prevent zfs from being automounted by fstab auto discovery & zfs
|
||||
fileSystems."/storage/dataset".options = ["noauto"];
|
||||
fileSystems."/storage".options = ["noauto"];
|
||||
fileSystems = {
|
||||
"/storage/dataset".options = [ "noauto" ];
|
||||
"/storage".options = [ "noauto" ];
|
||||
|
||||
fileSystems."/home/ghoscht/.zfs" = {
|
||||
"/home/ghoscht/.zfs" = {
|
||||
device = "/dev/disk/by-label/SECRET_KEYS";
|
||||
fsType = "vfat";
|
||||
};
|
||||
};
|
||||
|
||||
users.mutableUsers = true;
|
||||
users.users.${vars.user} = {
|
||||
|
|
|
@ -1,18 +1,16 @@
|
|||
{
|
||||
pkgs,
|
||||
inputs,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
vars = import ../../vars.nix;
|
||||
in {
|
||||
{ pkgs
|
||||
, inputs
|
||||
, ...
|
||||
}: {
|
||||
imports = [
|
||||
inputs.sops-nix.nixosModules.sops
|
||||
];
|
||||
|
||||
environment.systemPackages = with pkgs; [ sops ];
|
||||
|
||||
sops.defaultSopsFile = ../../secrets/franz.yaml;
|
||||
sops.defaultSopsFormat = "yaml";
|
||||
sops.age.keyFile = "/home/${vars.user}/.config/sops/age/keys.txt";
|
||||
sops = {
|
||||
defaultSopsFile = ../../secrets/franz.yaml;
|
||||
defaultSopsFormat = "yaml";
|
||||
age.keyFile = "/sops-nix/sops.txt";
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue