150: Future rebuilds should use the flake, not configuration.nix r=zimbatm a=JillThornhill



Co-authored-by: JillThornhill <121565493+JillThornhill@users.noreply.github.com>
Co-authored-by: JillThornhill <jill.thornhill@zol.co.zw>
This commit is contained in:
bors[bot] 2023-07-09 12:56:29 +00:00 committed by GitHub
commit 04f9809803
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 18 additions and 0 deletions

View File

@ -199,6 +199,15 @@ Note that this command references the URL of your flake, in this case `.#`,
together with the name of the system `hetzner-cloud`, as highlighted by the
comment in the sample flake.
This will configure and build the new NixOS server. Since the configurations are
defined in the flake, it will not create `/etc/nixos/configuration.nix`. If you
need to make changes to the configuration in future, you should make the changes
in the flake, and rebuild using the --flake option as shown below:
```
nixos-rebuild --flake <flake URL> switch
```
The [Quickstart Guide](./docs/quickstart.md) gives more information on how to
run **nixos-anywhere** in its simplest form. For more specific instructions to
suit individual requirements, see the [How To Guide](./docs/howtos.md).

View File

@ -158,6 +158,15 @@ directory containing the flake to update `flake.lock` before rerunning
nix flake update
```
The new server's configurations are defined in the flake. `nixos-anywhere` does
not create `etc/nixos/configuration.nix`since it expects the server to be
administered remotely. Any future changes to the configuration should be made to
the flake, and you would reference this flake when doing the rebuild:
```
nixos-rebuild --flake <URL to your flake> switch
```
For more information on different use cases of **nixos-anywhere** please refer
to the [How to Guide](./howtos.md), and for more technical information and
explanation of known error messages, refer to the