2024-08-24 22:16:51 -04:00
|
|
|
{
|
2024-09-02 23:51:58 -04:00
|
|
|
description = "Jimbo's systems as a flake";
|
2024-08-24 22:16:51 -04:00
|
|
|
|
|
|
|
inputs = {
|
|
|
|
# Nixpkgs
|
|
|
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05";
|
|
|
|
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
|
|
|
|
nur.url = "github:nix-community/NUR";
|
|
|
|
nixos-mailserver.url = "gitlab:simple-nixos-mailserver/nixos-mailserver/nixos-24.05";
|
2024-08-26 19:43:59 -04:00
|
|
|
blender-bin.url = "https://flakehub.com/f/edolstra/blender-bin/1.0.8.tar.gz";
|
2024-08-30 14:17:21 -04:00
|
|
|
nix-minecraft.url = "github:Infinidoge/nix-minecraft";
|
2024-09-05 06:00:11 -04:00
|
|
|
nixos-hardware.url = "github:nixos/nixos-hardware/master";
|
2024-08-24 22:16:51 -04:00
|
|
|
|
|
|
|
# Home manager
|
|
|
|
home-manager = {
|
|
|
|
url = "github:nix-community/home-manager/release-24.05";
|
|
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
outputs = {
|
2024-08-26 19:43:59 -04:00
|
|
|
self,
|
|
|
|
nixpkgs,
|
2024-09-02 23:51:58 -04:00
|
|
|
nixpkgs-unstable,
|
2024-08-24 22:16:51 -04:00
|
|
|
nur,
|
|
|
|
nixos-mailserver,
|
2024-08-27 05:14:19 -04:00
|
|
|
blender-bin,
|
2024-08-26 19:43:59 -04:00
|
|
|
home-manager,
|
2024-08-24 22:16:51 -04:00
|
|
|
...
|
|
|
|
} @inputs: let
|
|
|
|
inherit (self) outputs;
|
|
|
|
forAllSystems = nixpkgs.lib.genAttrs [
|
2024-08-26 19:43:59 -04:00
|
|
|
"aarch64-linux"
|
2024-08-24 22:16:51 -04:00
|
|
|
"x86_64-linux"
|
|
|
|
];
|
|
|
|
in rec {
|
|
|
|
# Your custom packages
|
|
|
|
# Accessible through 'nix build', 'nix shell', etc
|
|
|
|
packages = forAllSystems (system: import ./pkgs nixpkgs.legacyPackages.${system});
|
|
|
|
|
|
|
|
# Your custom packages and modifications, exported as overlays
|
|
|
|
overlays = import ./overlays {inherit inputs;};
|
|
|
|
|
2024-08-30 01:17:50 -04:00
|
|
|
# Secrets defined so they can be accessed globally
|
|
|
|
secrets = import ./secrets.nix;
|
|
|
|
|
2024-08-24 22:16:51 -04:00
|
|
|
# NixOS configuration entrypoint, use 'nixos-rebuild --flake .#your-hostname'
|
|
|
|
nixosConfigurations = {
|
2024-08-26 13:07:59 -04:00
|
|
|
JimDesktop = nixpkgs.lib.nixosSystem {
|
2024-08-24 22:16:51 -04:00
|
|
|
specialArgs = {inherit inputs outputs;};
|
|
|
|
modules = [
|
|
|
|
./nixos/desktop.nix
|
|
|
|
];
|
|
|
|
};
|
2024-08-26 13:07:59 -04:00
|
|
|
JimServer = nixpkgs.lib.nixosSystem {
|
2024-08-24 22:16:51 -04:00
|
|
|
specialArgs = {inherit inputs outputs;};
|
|
|
|
modules = [
|
|
|
|
./nixos/server.nix
|
|
|
|
nixos-mailserver.nixosModule
|
|
|
|
];
|
|
|
|
};
|
2024-09-08 21:45:54 -04:00
|
|
|
JimLenovo = nixpkgs.lib.nixosSystem {
|
|
|
|
specialArgs = {inherit inputs outputs;};
|
|
|
|
modules = [
|
|
|
|
./nixos/lenovo.nix
|
|
|
|
];
|
|
|
|
};
|
2024-08-24 22:16:51 -04:00
|
|
|
};
|
|
|
|
|
2024-09-03 01:01:58 -04:00
|
|
|
# Standalone home-manager configuration
|
2024-08-24 22:16:51 -04:00
|
|
|
# Available through 'home-manager --flake .#your-username@your-hostname'
|
|
|
|
homeConfigurations = {
|
2024-08-26 13:07:59 -04:00
|
|
|
"jimbo@JimDesktop" = home-manager.lib.homeManagerConfiguration {
|
2024-08-24 22:16:51 -04:00
|
|
|
pkgs = nixpkgs.legacyPackages.x86_64-linux;
|
|
|
|
extraSpecialArgs = {inherit inputs outputs;};
|
|
|
|
modules = [
|
|
|
|
./home-manager/jimbo_desktop.nix
|
|
|
|
nur.nixosModules.nur
|
|
|
|
];
|
|
|
|
};
|
2024-08-26 13:07:59 -04:00
|
|
|
"jimbo@JimServer" = home-manager.lib.homeManagerConfiguration {
|
2024-08-24 22:16:51 -04:00
|
|
|
pkgs = nixpkgs.legacyPackages.x86_64-linux;
|
|
|
|
extraSpecialArgs = {inherit inputs outputs;};
|
|
|
|
modules = [
|
|
|
|
./home-manager/jimbo_server.nix
|
|
|
|
];
|
|
|
|
};
|
2024-09-08 21:45:54 -04:00
|
|
|
"jimbo@JimLenovo" = home-manager.lib.homeManagerConfiguration {
|
|
|
|
pkgs = nixpkgs.legacyPackages.x86_64-linux;
|
|
|
|
extraSpecialArgs = {inherit inputs outputs;};
|
|
|
|
modules = [
|
|
|
|
./home-manager/jimbo_lenovo.nix
|
|
|
|
nur.nixosModules.nur
|
|
|
|
];
|
|
|
|
};
|
2024-08-27 15:17:32 -04:00
|
|
|
# Derivation for ssh envrionments on other people's servers
|
|
|
|
"jimbo@SSH" = home-manager.lib.homeManagerConfiguration {
|
|
|
|
pkgs = nixpkgs.legacyPackages.x86_64-linux;
|
|
|
|
extraSpecialArgs = {inherit inputs outputs;};
|
|
|
|
modules = [
|
|
|
|
./home-manager/jimbo_ssh.nix
|
|
|
|
];
|
|
|
|
};
|
2024-08-24 22:16:51 -04:00
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|