MyNixOS website logo

Systems with a recently generated hardware-configuration.nix do not need to specify this option, unless cross-compiling, in which case you should set onlynixpkgs.buildPlatform.

If this is somehow not feasible, you may fall back to removing the nixpkgs.hostPlatform line from the generated config and use the old options.

Specifies the platform on which NixOS should be built. When nixpkgs.crossSystem is unset, it also specifies the platform for which NixOS should be built. If this option is unset, it defaults to the platform type of the machine where evaluation happens. Specifying this option is useful when doing distributed multi-platform deployment, or when building virtual machines. See its description in the Nixpkgs manual for more details.

Ignored when nixpkgs.pkgs or hostPlatform is set.

Declarations
Type
attribute set
Default
(import "${nixos}/../lib").lib.systems.examples.aarch64-multiplatform
Example
{
  system = "aarch64-linux";
}