Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minimal nixos-config with disko #1

Merged
merged 17 commits into from
Nov 17, 2023
Merged

Minimal nixos-config with disko #1

merged 17 commits into from
Nov 17, 2023

Conversation

shivaraj-bh
Copy link
Member

@shivaraj-bh shivaraj-bh commented Nov 10, 2023

WIP blog post: juspay/flakular.in#25

@srid
Copy link
Member

srid commented Nov 11, 2023

Is this already deployed, or waiting to be deployed?

@shivaraj-bh
Copy link
Member Author

Is this already deployed, or waiting to be deployed?

Already deployed

@srid
Copy link
Member

srid commented Nov 11, 2023

Already deployed

In that case, let's add to README the instructions for deployment. As a next step, we'll had this over to another person for doing deployments for their machine.

README.md Outdated
| 3. | In `disk-config.nix`, set `disko.devices.disk.main.device = "/dev/<device-name>";` | |
| 4. | | `nix run github:nix-community/nixos-anywhere -- --flake .#office root@<ip-address>` |

**Disclaimer**: The `<ip-address>` might change in kexec mode or post-installation, in which case you will have to stop the `Step 4` and rerun with updated `<ip-address>`.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we clarify this further?

When you say stop the Step 4, what is meant exactly? At what point (during the nix run ... process) exactly should the user stop it with Ctrl+C? Or is it that they must wait for it to error out (in which case, there is no need to stop the nix run ... process because it is already stopped), and then re-run it? If so, it would be useful to paste that error message here.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also how do we find out the new ip address? It is worth including that as well.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(Disclaimer: I might be missing something, so we can also revisit these instructions after the actual install ....)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At what point (during the nix run ... process) exactly should the user stop it with Ctrl+C?

When the ssh starts timing out. I will add that point

README.md Outdated Show resolved Hide resolved
@srid
Copy link
Member

srid commented Nov 16, 2023

FWIW, trying this PR (with changes to ssh key/ disk path) on Digital Ocean shared droplet:

image

SSH just hangs, even after restarting the droplet.

image

It is possible that the bootloader configuration needs a change for Digital Ocean. This may be worth making a note of in README (we are so far assuming a particular i9 desktop configuration).

@shivaraj-bh
Copy link
Member Author

FWIW, trying this PR (with changes to ssh key/ disk path) on Digital Ocean shared droplet:

image SSH just hangs, even after restarting the droplet. image It is possible that the bootloader configuration needs a change for Digital Ocean. This may be worth making a note of in README (we are so far assuming a particular i9 desktop configuration).

Could be because your instance might not support EFI firmware? is it possible to run this on the droplet instance: efibootmgr?

If that's the case, we can try by removing the EFI related lines from the configuration. It should not use EFI by default: https://search.nixos.org/options?channel=23.05&show=boot.loader.grub.efiSupport&from=0&size=50&sort=relevance&type=packages&query=efiSupport

@srid srid merged commit a23acb9 into main Nov 17, 2023
1 check passed
@srid srid deleted the init-nixos-config branch November 17, 2023 15:09
@shivaraj-bh
Copy link
Member Author

Digital ocean droplet instance wouldn't boot because of the absence of qemu-guest.nix module. After using this, it does boot up but fails to automatically detect networking configuration (this could be because it is a VM instance).

Solutions like nixos-infect work by generating a networking.nix configuration during runtime on the host, before installing NixOS.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants