2023-06-11 23:09:59 +02:00
|
|
|
# SPDX-FileCopyrightText: 2022 Richard Brežák <richard@brezak.sk>
|
|
|
|
#
|
|
|
|
# SPDX-License-Identifier: LGPL-3.0-or-later
|
2023-06-18 20:07:47 +02:00
|
|
|
{ inputs, lib', config, secret, ... }:
|
2023-06-11 23:09:59 +02:00
|
|
|
let
|
2023-06-18 20:07:47 +02:00
|
|
|
inherit (lib')
|
2023-06-11 23:09:59 +02:00
|
|
|
flip
|
|
|
|
mapAttrs
|
2023-06-18 20:07:47 +02:00
|
|
|
singleton
|
|
|
|
loadSecrets;
|
2023-06-11 23:09:59 +02:00
|
|
|
|
|
|
|
config' = config;
|
|
|
|
in
|
|
|
|
{
|
|
|
|
flake.nixosConfigurations.omen = inputs.nixpkgs.lib.nixosSystem {
|
|
|
|
system = "x86_64-linux";
|
2023-06-18 20:07:47 +02:00
|
|
|
lib = lib';
|
2023-06-11 23:09:59 +02:00
|
|
|
|
|
|
|
specialArgs = {
|
|
|
|
config' = config';
|
|
|
|
inputs' = inputs;
|
2023-06-18 20:07:47 +02:00
|
|
|
secret = loadSecrets inputs.secret;
|
2023-06-11 23:09:59 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
modules = singleton
|
|
|
|
({ pkgs, config, ... }:
|
|
|
|
{
|
|
|
|
imports = [
|
|
|
|
./xserver.nix
|
|
|
|
../../common/steam.nix
|
|
|
|
./grub.nix
|
|
|
|
./networking.nix
|
|
|
|
./filesystems.nix
|
|
|
|
./hardware.nix
|
|
|
|
./users.nix
|
|
|
|
./nixpkgs.nix
|
|
|
|
../../common/sound.nix
|
|
|
|
|
|
|
|
inputs.dwarffs.nixosModules.dwarffs
|
|
|
|
];
|
|
|
|
|
|
|
|
_module.args.nixinate = {
|
|
|
|
host = secret.network.ips.omen.vpn or "";
|
|
|
|
sshUser = "main";
|
|
|
|
buildOn = "local";
|
|
|
|
substituteOnTarget = true;
|
|
|
|
hermetic = false;
|
|
|
|
nixOptions = [
|
|
|
|
"--override-input secret path://$HOME/dotfiles/secret"
|
|
|
|
];
|
|
|
|
};
|
|
|
|
|
|
|
|
services.fwupd.enable = true;
|
|
|
|
|
|
|
|
services.syncthing = {
|
|
|
|
enable = true;
|
|
|
|
user = "main";
|
|
|
|
group = "main";
|
|
|
|
};
|
|
|
|
|
|
|
|
services.sshd.enable = true;
|
|
|
|
|
|
|
|
# Makes QEMU recompile https://github.com/NixOS/nixpkgs/issues/221056
|
2023-06-28 14:22:27 +02:00
|
|
|
boot.binfmt.emulatedSystems = [
|
|
|
|
"aarch64-linux"
|
|
|
|
"riscv64-linux"
|
|
|
|
];
|
2023-06-11 23:09:59 +02:00
|
|
|
|
|
|
|
time.timeZone = "Europe/Amsterdam";
|
|
|
|
system.stateVersion = "20.09";
|
|
|
|
|
|
|
|
virtualisation.podman.enable = true;
|
2023-07-18 11:45:37 +02:00
|
|
|
virtualisation.podman.dockerCompat = true;
|
2023-06-11 23:09:59 +02:00
|
|
|
});
|
|
|
|
};
|
|
|
|
}
|