Created
April 1, 2024 19:17
-
-
Save PerchunPak/00acc9f000667c5c4dca4b8d4a6c76b0 to your computer and use it in GitHub Desktop.
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
[nixos@nixos:~/nixos-dotfiles]$ sudo nix --experimental-features "nix-command flakes" run github:nix-community/disko -- --mode create ./modules/nixos/disko.nix --arg device '"/dev/vda"' | |
trace: the create output is deprecated, use format instead | |
this derivation will be built: | |
/nix/store/g6qdlfivkbr0xa9j6v4kl97sg789jvmw-disko-format.drv | |
building '/nix/store/g6qdlfivkbr0xa9j6v4kl97sg789jvmw-disko-format.drv'... | |
++ mktemp -d | |
+ disko_devices_dir=/tmp/tmp.S66ppwTquk | |
+ trap 'rm -rf "$disko_devices_dir"' EXIT | |
+ mkdir -p /tmp/tmp.S66ppwTquk | |
+ device=/dev/vda | |
+ imageSize=2G | |
+ name=main | |
+ type=disk | |
+ device=/dev/vda | |
+ efiGptPartitionFirst=1 | |
+ type=gpt | |
+ blkid /dev/vda | |
+ device=/dev/disk/by-partlabel/disk-main-ESP | |
+ extraArgs=() | |
+ declare -a extraArgs | |
+ format=vfat | |
+ mountOptions=('defaults') | |
+ declare -a mountOptions | |
+ mountpoint=/boot | |
+ type=filesystem | |
+ blkid /dev/disk/by-partlabel/disk-main-ESP | |
+ grep -q TYPE= | |
+ mkfs.vfat /dev/disk/by-partlabel/disk-main-ESP | |
mkfs.fat 4.2 (2021-01-31) | |
mkfs.vfat: unable to open /dev/disk/by-partlabel/disk-main-ESP: No such file or directory | |
+ rm -rf /tmp/tmp.S66ppwTquk | |
[nixos@nixos:~/nixos-dotfiles]$ git diff | |
diff --git a/modules/nixos/disko.nix b/modules/nixos/disko.nix | |
index 04d7ded..67b5bd9 100644 | |
--- a/modules/nixos/disko.nix | |
+++ b/modules/nixos/disko.nix | |
@@ -6,6 +6,8 @@ | |
content = { | |
type = "gpt"; | |
partitions = { | |
+ fedora_boot = {}; | |
+ fedora_main = {}; | |
boot = { | |
name = "boot"; | |
size = "1M"; | |
[nixos@nixos:~/nixos-dotfiles]$ lsblk | |
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS | |
loop0 7:0 0 904.4M 1 loop /nix/.ro-store | |
sr0 11:0 1 950M 0 rom /iso | |
vda 253:0 0 20G 0 disk | |
├─vda1 253:1 0 250.5K 0 part | |
└─vda2 253:2 0 10G 0 part | |
[nixos@nixos:~/nixos-dotfiles]$ ls /dev/disk/by-partlabel/disk-main-ESP | |
ls: cannot access '/dev/disk/by-partlabel/disk-main-ESP': No such file or directory | |
[nixos@nixos:~/nixos-dotfiles]$ ls /dev/disk/by-partlabel/ | |
ls: cannot access '/dev/disk/by-partlabel/': No such file or directory | |
[nixos@nixos:~/nixos-dotfiles]$ ls /dev/disk/ | |
by-diskseq by-id by-label by-partuuid by-path by-uuid |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment