-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e8f9ab9
commit d95f940
Showing
4 changed files
with
35 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,46 +1,47 @@ | ||
# This is a basic NixOS flake template for a live ISO image | ||
# that can be used to install NixOS on a system. | ||
# ISO can be built using | ||
# ISO can be built using | ||
# `nix build .#nixosConfigurations.nixos-iso.config.system.build.isoImage` - Graphical ISO | ||
# `nix build .#nixosConfigurations.nixos-minimal.config.system.build.isoImage` - Minimal ISO | ||
# Make sure to enable flakes and nix-command on the host system, before building the ISO | ||
# Resulting image can be found in ./result/iso/ directory | ||
|
||
{ | ||
description = "Unstable NixOS custom installation media"; | ||
inputs = { | ||
nixpkgs.url = "nixpkgs/nixos-unstable"; | ||
bcachefs-tools.url = "github:koverstreet/bcachefs-tools"; | ||
}; | ||
outputs = | ||
{ self, nixpkgs, ... }@inputs: | ||
let | ||
system = "x86_64-linux"; # change arch here | ||
outputs = { | ||
self, | ||
nixpkgs, | ||
... | ||
} @ inputs: let | ||
system = "x86_64-linux"; # change arch here | ||
|
||
specialArgs = { | ||
inherit system; | ||
inherit inputs; | ||
}; | ||
in | ||
{ | ||
## GRAPHICAL ISO ## | ||
nixosConfigurations.nixos-iso = nixpkgs.lib.nixosSystem { | ||
inherit system; | ||
modules = [ | ||
"${nixpkgs}/nixos/modules/installer/cd-dvd/installation-cd-graphical-gnome.nix" | ||
"${nixpkgs}/nixos/modules/installer/cd-dvd/channel.nix" | ||
./graphical-configuration.nix | ||
]; | ||
inherit specialArgs; | ||
}; | ||
## MINIMAL ISO ## | ||
nixosConfigurations.nixos-minimal = nixpkgs.lib.nixosSystem { | ||
inherit system; | ||
modules = [ | ||
"${nixpkgs}/nixos/modules/installer/cd-dvd/installation-cd-minimal.nix" | ||
./minimal-configuration.nix | ||
]; | ||
inherit specialArgs; | ||
}; | ||
specialArgs = { | ||
inherit system; | ||
inherit inputs; | ||
}; | ||
in { | ||
formatter.${system} = nixpkgs.legacyPackages.${system}.alejandra; | ||
## GRAPHICAL ISO ## | ||
nixosConfigurations.nixos-iso = nixpkgs.lib.nixosSystem { | ||
inherit system; | ||
modules = [ | ||
"${nixpkgs}/nixos/modules/installer/cd-dvd/installation-cd-graphical-gnome.nix" | ||
"${nixpkgs}/nixos/modules/installer/cd-dvd/channel.nix" | ||
./graphical-configuration.nix | ||
]; | ||
inherit specialArgs; | ||
}; | ||
## MINIMAL ISO ## | ||
nixosConfigurations.nixos-minimal = nixpkgs.lib.nixosSystem { | ||
inherit system; | ||
modules = [ | ||
"${nixpkgs}/nixos/modules/installer/cd-dvd/installation-cd-minimal.nix" | ||
./minimal-configuration.nix | ||
]; | ||
inherit specialArgs; | ||
}; | ||
}; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters