123 lines
4.5 KiB
Nix
123 lines
4.5 KiB
Nix
{
|
|
description = "LAN NixOS configs";
|
|
|
|
inputs = {
|
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
|
nixos-conf-editor.url = "github:snowfallorg/nixos-conf-editor";
|
|
home-manager = {
|
|
url = "github:nix-community/home-manager";
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
firefox-webapp = {
|
|
url = "github:TLATER/dotfiles";
|
|
# optional: specify a ref/branch if needed
|
|
};
|
|
};
|
|
|
|
outputs = { self, nixpkgs, nixos-conf-editor, home-manager, ... } @ inputs:
|
|
let system = "x86_64-linux"; in {
|
|
nixConfig = {
|
|
access-tokens = [
|
|
"github.com=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"
|
|
];
|
|
};
|
|
homeConfigurations = {
|
|
myUser = home-manager.lib.homeManagerConfiguration {
|
|
inherit nixpkgs;
|
|
modules = [
|
|
firefox-webapp.home-modules.firefox-webapp
|
|
];
|
|
configuration = { config, pkgs, ... }: {
|
|
programs.firefox.enable = true;
|
|
graphical.webapps = {
|
|
discord = {
|
|
url = "https://discord.com/app";
|
|
profile = "webapp_discord";
|
|
iconUrl = "https://discord.com/assets/icon.png";
|
|
name = "Discord Web";
|
|
windowClass = "DiscordWebApp";
|
|
};
|
|
telegram = {
|
|
url = "https://web.telegram.org";
|
|
profile = "webapp_telegram";
|
|
iconUrl = "https://telegram.org/img/t_logo.png";
|
|
name = "Telegram Web";
|
|
windowClass = "TelegramWebApp";
|
|
};
|
|
};
|
|
};
|
|
};
|
|
};
|
|
nixosConfigurations = {
|
|
# automatically use each host folder by name
|
|
nixos = nixpkgs.lib.nixosSystem {
|
|
inherit system;
|
|
modules = [
|
|
./hosts/nixos/configuration.nix
|
|
./common/hardware-configuration.nix
|
|
home-manager.nixosModules.home-manager {
|
|
home-manager.useGlobalPkgs = true;
|
|
home-manager.useUserPackages = true;
|
|
home-manager.users.nixos = import ./hosts/nixos/home.nix;
|
|
|
|
}
|
|
];
|
|
|
|
|
|
|
|
specialArgs = { inherit inputs; };
|
|
};
|
|
docker = nixpkgs.lib.nixosSystem {
|
|
inherit system;
|
|
modules = [
|
|
./hosts/docker/configuration.nix
|
|
./common/hardware-configuration.nix
|
|
home-manager.nixosModules.home-manager {
|
|
home-manager.useGlobalPkgs = true;
|
|
home-manager.useUserPackages = true;
|
|
home-manager.users.nixos = import ./common/home.nix;
|
|
}
|
|
];
|
|
};
|
|
server = nixpkgs.lib.nixosSystem {
|
|
inherit system;
|
|
modules = [
|
|
./hosts/server/configuration.nix
|
|
./common/hardware-configuration.nix
|
|
home-manager.nixosModules.home-manager {
|
|
home-manager.useGlobalPkgs = true;
|
|
home-manager.useUserPackages = true;
|
|
home-manager.users.nixos = import ./common/home.nix;
|
|
}
|
|
];
|
|
};
|
|
nix-cache = nixpkgs.lib.nixosSystem {
|
|
inherit system;
|
|
modules = [
|
|
./hosts/nix-cache/configuration.nix
|
|
./common/hardware-configuration.nix
|
|
home-manager.nixosModules.home-manager {
|
|
home-manager.useGlobalPkgs = true;
|
|
home-manager.useUserPackages = true;
|
|
home-manager.users.nixos = import ./common/home.nix;
|
|
}
|
|
];
|
|
|
|
};
|
|
nix-minimal = nixpkgs.lib.nixosSystem {
|
|
inherit system;
|
|
modules = [
|
|
./hosts/nix-minimal/configuration.nix
|
|
./common/hardware-configuration.nix
|
|
home-manager.nixosModules.home-manager {
|
|
home-manager.useGlobalPkgs = true;
|
|
home-manager.useUserPackages = true;
|
|
home-manager.users.nixos = import ./common/home.nix;
|
|
}
|
|
];
|
|
|
|
};
|
|
};
|
|
};
|
|
}
|