Skip to content

Commit

Permalink
don't recommend starting from an empty flake...
Browse files Browse the repository at this point in the history
...as we've received feedback that this is  more
confusing for newer users than starting from the
example and it's probably safe to assume more experienced
users will be able to figure it out on their own.
  • Loading branch information
phaer authored and mergify[bot] committed Oct 20, 2023
1 parent 3ce8720 commit c1d2893
Showing 1 changed file with 13 additions and 22 deletions.
35 changes: 13 additions & 22 deletions docs/quickstart.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,33 +32,24 @@ below.

## Steps required to run nixos-anywhere

1. **Enable Flakes and Create a Directory**:
1. **Enable Flakes**:

- Ensure that flakes are enabled on your system. To enable flakes, refer to
the [NixOS Wiki](https://nixos.wiki/wiki/Flakes#enable-flakes).
- Create a directory to store the flake and configuration files.
Ensure that flakes are enabled on your system. To enable flakes, refer to the
[NixOS Wiki](https://nixos.wiki/wiki/Flakes#enable-flakes).

2. **Initialize a Flake**: Within the newly-created directory, execute the
command:
2. **Initialize a Flake**:

```bash
nix flake init
```

This command will generate a `flake.nix` file. Modify this file according to
your requirements.

- **For a Minimal Setup**:\
You can copy and paste the example flake contents available
[here](https://github.com/numtide/nixos-anywhere-examples/blob/main/flake.nix).
This example is tailored for a virtual machine setup similar to one on
[Hetzner Cloud](https://www.hetzner.com/cloud).
The easiest way to start is to copy our
[example flake.nix](https://github.com/numtide/nixos-anywhere-examples/blob/main/flake.nix)
into a new directory. This example is tailored for a virtual machine setup
similar to one on [Hetzner Cloud](https://www.hetzner.com/cloud), so you
might need to adapt it for your setup.

**Hardware-Specific Configuration**: If you're not using a virtual machine,
you'll need to generate a custom hardware configuration with
`nixos-generate-config`.
**Hardware-Specific Configuration**: If you're not using a virtual machine,
you'll need to generate a custom hardware configuration with
`nixos-generate-config`.

- **Getting `nixos-generate-config` on Target Machine**:
- **Get `nixos-generate-config` onto the Target Machine**:

1. **Option 1**: If NixOS is not installed, boot into an installer without
first installing NixOS.
Expand Down

0 comments on commit c1d2893

Please sign in to comment.