Jörg Thalheim
725ea35e41
luks: retry the interactive password prompt on mismatch ( #1297 )
...
askPassword's mismatch branch does exit 1, which kills the whole format
script instead of just returning from the function. The per-device
_create block runs in a subshell, and the top-level script has set
-efux, so a subshell that exits nonzero takes the whole thing down with
it.
The retry loop this was supposed to feed into never gets a chance to
run:
```
until askPassword; do
echo "Passwords did not match, please try again."
done
```
`askPassword` never returns from the mismatch branch, so until never
sees a nonzero return, it just watches the whole script die. Type your
password wrong once during formatting and disko doesn't ask again, it
aborts.
Same bug and same fix as #1206 (exit 1 -> return 1), which has been
sitting unreviewed for a while. Credit to @Cyclic4179 for finding it
first.
While in there, I also capped the retry loop at 3 attempts. As written
it would otherwise retry forever, and a script that just hangs asking
for input with no way out isn't much better than one that silently dies.
3 also isn't arbitrary: it's what tries= defaults to in crypttab(5) for
unlocking this same kind of volume at boot, so the format-time prompt
now matches that.
Added tests/luks-password-mismatch.nix covering both paths:
**a mismatched pair followed by a matching one:** format should succeed,
and the retry message should actually show up in the output.
**three mismatched pairs in a row:** format should fail, the disk should
not end up as valid LUKS, and the "too many attempts" message should be
there instead of a silent exit code 1.
Both fail on current master and pass with this change.
2026-09-18 22:31:26 +00:00
Jörg Thalheim
878ec37d6a
Escape ZFS args ( #1222 )
...
Args to ZFS (like mountpoints) might have spaces or other
shell-unfriendly characters in them. This escapes those so they get
passed to zfs correctly.
2026-03-14 16:38:37 +00:00
Jörg Thalheim
c4d34f2031
fix: correct typos across docs and messages ( #1229 )
...
## Summary
This PR fixes typos in docs and user-facing messages.
## Detailed Changes
| File | Fixed |
|---|---|
| `scripts/create-release.nix` | `uncommited` -> `uncommitted` (4x) |
| `lib/default.nix:906` | `Depracated` -> `Deprecated` |
| `lib/tests.nix:195` | `mkOveride` -> `mkOverride` |
| `docs/interactive-vm.md:3` | `similiar` -> `similar` |
| `docs/disko-images.md:82` | `involed` -> `involved` |
| `docs/disko-images.md:110` | `scirpt` -> `script` |
| `docs/table-to-gpt.md:62` | `partiton` -> `partition` |
| `lib/make-disk-image.nix:212` | `involed` -> `involved` |
| `docs/disko-images.md:11` | `In the this example` -> `In this example`
|
No intended behavior change.
Closes #1228
2026-03-14 16:34:36 +00:00
Jörg Thalheim
6ef4eafa8e
ci: fix PRs not merged automatically redux ( #1212 )
...
To match nixos-anywhere's setup :)
2026-02-17 10:33:07 +00:00
Jörg Thalheim
6bb82b77ce
luks: drop unnecessary subshell
2025-05-08 09:13:14 +00:00
Jörg Thalheim
0d8c6ad4a4
Merge pull request #990 from meck/fix_cache_miss
...
Set `buildPlatform` in make-disk-image
2025-03-12 14:31:55 +01:00
Jörg Thalheim
0c8f1b9eab
Merge pull request #977 from nix-community/update_flake_lock_action
...
flake.lock: Update
2025-03-12 14:13:09 +01:00
Jörg Thalheim
46b9f51eb6
Merge pull request #993 from nix-community/disk-deactivate-fix
...
Disk deactivate fix
2025-03-12 13:36:50 +01:00
Jörg Thalheim
bf0abfde48
Merge pull request #941 from LogicalOverflow/master
...
fix eval of `zfs_volume`'s `_unmount` if `content` is `null`
2025-01-16 15:34:23 +01:00
Jörg Thalheim
33827d2bd1
Merge pull request #923 from whs-dot-hk/fix-typo
...
Fix typo
2025-01-11 11:38:24 +01:00
Jörg Thalheim
b1a94497b1
Merge pull request #935 from nix-community/install-grub-devs
...
install-cli: use disks from diskMappings arg for grub devices
2025-01-10 17:32:08 +01:00
Jörg Thalheim
84a5b93637
Merge pull request #928 from aos/aos/xfs-options
...
doc: simple xfs with options
2024-12-29 11:39:13 +01:00
Jörg Thalheim
3a4de9fa3a
Merge pull request #924 from nix-community/vdev
...
zfs-with-vdevs: add an example for using absolute device paths
2024-12-24 14:54:06 +01:00
Jörg Thalheim
2ee76c861a
Merge pull request #921 from nix-community/zfs-fix
...
zfs: run load-key on mount/unmount
2024-12-20 14:26:41 +01:00
Jörg Thalheim
600d2e1d2f
Merge pull request #922 from nix-community/update_flake_lock_action
...
flake.lock: Update
2024-12-20 14:22:38 +01:00
Jörg Thalheim
a08bfe06b3
Merge pull request #920 from nix-community/update_flake_lock_action
...
flake.lock: Update
2024-12-16 11:03:32 +01:00
Jörg Thalheim
2097ca7a9e
Merge pull request #916 from 0x450x6c/zvol_extra_args
...
Add extraArgs to zfs_volume.
2024-12-13 12:07:58 +01:00
Jörg Thalheim
825605c2c7
Merge pull request #911 from nix-community/avoid-mv
...
make-disk-image: create directories images in out path
2024-12-13 11:16:20 +01:00
Jörg Thalheim
0f31ad735e
Merge pull request #903 from nix-community/update_flake_lock_action
...
flake.lock: Update
2024-12-12 14:46:32 +01:00
Jörg Thalheim
b71e3faca9
Merge pull request #906 from nix-community/fix-904
...
make-disk-image: Compare against correct nixpkgs version
2024-11-29 23:29:22 +01:00
Jörg Thalheim
a75ba3b87b
Merge pull request #891 from nix-community/verity
...
Add declarative unmount
2024-11-29 16:39:43 +01:00
Jörg Thalheim
341482e2f4
Merge pull request #901 from samularity/patch-1
...
fix new logo in quickstart.md
2024-11-27 22:26:18 +01:00
Jörg Thalheim
2ed5e30fc7
Merge pull request #896 from nix-community/update_flake_lock_action
...
flake.lock: Update
2024-11-25 14:09:23 +01:00
Jörg Thalheim
f35ae6300f
Merge pull request #897 from nbdd0121/gpt-unformatted
...
Fix evaluation when a GPT partition is left unformatted
2024-11-25 14:09:07 +01:00
Jörg Thalheim
47bc8dfb6f
Merge pull request #895 from nix-community/fix-mountoptions
...
also passthrough rootfs mountoptions
2024-11-24 22:11:48 +01:00
Jörg Thalheim
abc8baff33
Merge pull request #890 from nix-community/disko-install
...
disko-install: dry-run improvements
2024-11-22 15:10:44 +01:00
Jörg Thalheim
84dd8eea9a
Merge pull request #892 from zimbatm/nix-2.3-compat
...
fix: restore nix 2.3 compatibility
2024-11-22 12:52:18 +01:00
Jörg Thalheim
97c0c4d707
Merge pull request #888 from nix-community/update_flake_lock_action
...
flake.lock: Update
2024-11-21 21:36:44 +01:00
Jörg Thalheim
a0c384e0a3
Merge pull request #883 from MaienM/feature/zfs-vdev-types
...
ZFS: Add log, spare & dedup vdev types, support multiple special vdevs, fix bug with mixed vdev types
2024-11-20 14:27:12 +01:00
Jörg Thalheim
486250f404
Merge pull request #869 from nix-community/fix-legacy-command-cli
...
cli: Fix legacy aliases
2024-11-10 22:31:31 +01:00
Jörg Thalheim
5e40e02978
Merge pull request #761 from nix-community/update_flake_lock_action
...
flake.lock: Update
2024-11-08 11:14:24 +01:00
Jörg Thalheim
051ff61420
Merge pull request #864 from nix-community/offline-installer
...
fix offline installation
2024-11-08 08:35:22 +01:00
Jörg Thalheim
60d4914b98
Merge pull request #842 from nix-community/write-scripts-to-bin-dir
...
outputs: make compatible with nix run and package lists
2024-11-08 06:57:04 +01:00
Jörg Thalheim
67dc29be30
Merge pull request #716 from beviu/fmt-check
...
Add --check option to formatter in flake
2024-09-26 15:59:51 +02:00
Jörg Thalheim
c1c472f4cd
Merge pull request #797 from r-vdp/always-add-dm-snapshot
...
Always add dm-snapshot when LVM is used
2024-09-25 09:39:37 +02:00
Jörg Thalheim
430ba34990
Merge pull request #793 from nix-community/joerg-ci
...
add workaround for failing zpool import test
2024-09-23 15:13:27 +02:00
Jörg Thalheim
0fe779905f
Merge pull request #785 from nix-community/smaller-fixes
...
Fix shellcheck for mounoptions with commas + escape filesystem args
2024-09-20 15:23:44 +02:00
Jörg Thalheim
624fd86460
Merge pull request #783 from nix-community/joerg-ci
...
update project logo
2024-09-19 21:58:46 +02:00
Jörg Thalheim
a31fe5ef16
Merge pull request #776 from Enzime/populate
...
module: always populate system.build attributes
2024-09-19 09:20:53 +02:00
Jörg Thalheim
22ee467a54
Merge pull request #775 from nix-community/dependabot/github_actions/cachix/install-nix-action-V28
...
build(deps): bump cachix/install-nix-action from V27 to 28
2024-09-17 00:07:47 +02:00
Jörg Thalheim
3632080c41
Merge pull request #764 from nix-community/dependabot/github_actions/DeterminateSystems/update-flake-lock-24
...
build(deps): bump DeterminateSystems/update-flake-lock from 23 to 24
2024-09-14 16:59:29 +02:00
Jörg Thalheim
4ef99d8ec4
Merge pull request #768 from nix-community/mergify/Mic92/config-update
...
ci(Mergify): configuration update
2024-09-13 11:17:20 +02:00
Jörg Thalheim
0f0b7f409d
ci(Mergify): configuration update
...
Signed-off-by: Jörg Thalheim <null>
2024-09-13 11:17:11 +02:00
Jörg Thalheim
37c83c08d1
Merge pull request #723 from dmadisetti/dm/zfs-extra
...
zfs: add ZFS "topology" features like explicit vdevs, cache, and special
2024-09-03 17:07:39 +02:00
Jörg Thalheim and Paul Haerle
5715bc02df
Update docs/interactive-vm.md
...
Co-authored-by: Paul Haerle <hello@phaer.org >
2024-08-20 17:13:58 +02:00
Jörg Thalheim and Paul Haerle
a7656d4827
Update README.md
...
Co-authored-by: Paul Haerle <hello@phaer.org >
2024-08-20 17:13:52 +02:00
Jörg Thalheim
fd43891af4
Merge pull request #737 from SuperSandro2000/patch-1
...
Fix options.json rendering
2024-08-18 17:50:16 +02:00
Jörg Thalheim
544a80a69d
Merge pull request #694 from nix-community/dependabot/github_actions/DeterminateSystems/update-flake-lock-23
...
build(deps): bump DeterminateSystems/update-flake-lock from 22 to 23
2024-07-01 22:05:45 +02:00
Jörg Thalheim
c1cfbfad7c
Merge pull request #670 from ginkogruen/patch-1
...
fix(docs): fixed typo in README.md
2024-06-10 10:33:59 +02:00
Jörg Thalheim
2540cc069f
Merge branch 'master' into patch-1
2024-06-10 10:14:22 +02:00
Jörg Thalheim
dd378f1d58
README: link to matrix channel
2024-06-09 08:19:24 +02:00
Jörg Thalheim
69e5942c9d
README: drop numtide contributing guidelines
...
We don't have anything for disko yet unfortunately.
fixes https://github.com/nix-community/disko/issues/671
2024-06-09 08:15:08 +02:00
Jörg Thalheim
a838e83e21
Merge pull request #662 from nix-community/dependabot/github_actions/DeterminateSystems/update-flake-lock-22
...
build(deps): bump DeterminateSystems/update-flake-lock from 21 to 22
2024-06-04 10:47:01 +02:00
Jörg Thalheim
5f7bdc7205
Merge pull request #652 from nix-community/joerg-ci
...
add diskoScript.drvPath for offline installations
2024-05-29 13:49:38 +02:00
Jörg Thalheim
b1389282b9
Merge pull request #348 from DavHau/dave
...
improve examples and zpool mode type
2023-09-05 08:04:11 +02:00
Jörg Thalheim
44bfe24a8e
Merge pull request #343 from nix-community/quick-start-update
...
grub: drop version 2 from docs
2023-09-02 18:52:42 +02:00
Jörg Thalheim
a4bf32f6f0
Merge pull request #341 from nix-community/zfs-hostid
...
do not set networking.hostId in vm tests by default
2023-09-02 18:41:18 +02:00
Jörg Thalheim
0eb913fe20
Merge pull request #342 from nix-community/platform-fixes
...
disable shellcheck for x86_32 and riscv64 in one place
2023-09-02 18:41:03 +02:00
Jörg Thalheim
3f47719a51
Merge pull request #317 from nix-community/joerg-ci
...
add missing tests
2023-08-10 13:47:20 +01:00
Jörg Thalheim
f2248036d2
Merge pull request #299 from nix-community/module-tests
...
allow using the disko test framework via the module
2023-07-21 13:37:39 +01:00
Jörg Thalheim
610e337bb2
Merge pull request #290 from nix-community/luks-keyFiles
...
types luks: pass keyFile to nixos config
2023-07-12 10:07:09 +01:00
Jörg Thalheim
fc3c3817c9
Merge pull request #283 from nix-community/update_flake_lock_action
...
flake.lock: Update
2023-07-05 09:09:56 +01:00
Jörg Thalheim
72e0068edd
Merge pull request #256 from nix-community/table_gpt
...
introduce new table_gpt type
2023-06-16 20:18:48 +01:00
Jörg Thalheim
f1178c6e72
Merge pull request #255 from nix-community/deadnix
...
apply deadnix
2023-06-07 17:10:39 +02:00
Jörg Thalheim
a5944cd574
Merge branch 'master' into bcachefs-fixes
2023-03-27 12:35:52 +01:00
Jörg Thalheim
fb91351af9
Merge pull request #143 from cscutcher/FORMAT
...
Standardise formatting with nixpkgs-fmt and some patterns with statix
2023-02-08 09:47:59 +01:00
Jörg Thalheim
309618f10a
Merge pull request #131 from nix-community/type-refactoring
...
Split disko type into multiple files
2023-01-30 11:26:56 +00:00
Jörg Thalheim
825be2b627
Merge pull request #123 from nix-community/doc
...
Revert "don't use bot token for flake updates"
2023-01-23 08:29:44 +00:00
Jörg Thalheim
8903d73825
Merge pull request #121 from nix-community/updates
...
don't use bot token for flake updates
2023-01-23 08:15:50 +00:00
Jörg Thalheim
bd435b2bc8
Merge pull request #106 from l0b0/feat/shellcheck
...
feat: ShellCheck
2023-01-10 08:18:17 +01:00
Jörg Thalheim
1006ff074c
Merge pull request #93 from nix-community/zfs-crypto
...
tests: change passphrase to secretsecret
2022-12-27 09:05:22 +00:00
Jörg Thalheim
f665b6b34d
Merge pull request #92 from nix-community/module-config
...
module: define only if devices are given
2022-12-25 21:27:52 +00:00
Jörg Thalheim
e3527b826d
Merge pull request #75 from nix-community/zap2
...
zap only devices we care about
2022-12-25 18:25:37 +00:00
Jörg Thalheim
8ae729e9be
Merge pull request #83 from lilyinstarlight/fix/swapon-typo
...
swap: fix typo for checking if swap is on
2022-12-23 16:42:23 +00:00
Jörg Thalheim
3ab2a5d98d
Merge pull request #90 from nix-community/kuutamo
...
mdadm: add single-disk raid support
2022-12-23 16:31:01 +00:00
Jörg Thalheim
936beccf8c
Merge pull request #91 from nix-community/fix-ci
...
pin nixpkgs again
2022-12-23 16:29:38 +00:00
Jörg Thalheim
f22e2fa834
Merge pull request #55 from therishidesai/rdesai/add-mmcblk-support
...
add support for mmc blk devices
2022-11-15 19:21:14 +01:00
Jörg Thalheim
c96ccd7d9f
Merge pull request #43 from nix-community/test-config
...
add nixos tests for disko.config
2022-10-04 11:30:22 +02:00
Jörg Thalheim
3a239145b6
Merge pull request #42 from nix-community/standalone
...
fix standalone example
2022-09-13 13:34:29 +02:00
Jörg Thalheim
c3da181593
Merge pull request #40 from moduon/refresh-after-partitioning
...
fix: mkfs randomly not detecting just partitioned device
2022-09-12 22:15:58 +02:00
Jörg Thalheim
0d3295fcff
Merge pull request #37 from nix-community/zfs
...
zfs: fix nixos config options
2022-09-05 16:28:42 +01:00
Jörg Thalheim
0c05616aa2
Merge pull request #36 from nix-community/nvme
...
fix nvme device names
2022-09-05 15:54:23 +01:00
Jörg Thalheim
4d50d08e81
Merge pull request #35 from nix-community/fix-example
...
fix example/default.nix
2022-09-05 13:12:32 +01:00
Jörg Thalheim
c0623a47d8
Merge pull request #34 from nix-community/types
...
README: fix example
2022-09-04 12:16:07 +01:00
Jörg Thalheim
fbc08430d2
Merge pull request #31 from nix-community/types
...
Reimplement using types
2022-09-04 12:11:54 +01:00
Jörg Thalheim
adf901d581
Merge pull request #27 from nix-community/zfs
...
zfs, lvm raid, btrfs subvolumes support & some fixups
2022-08-26 14:59:28 +01:00
Jörg Thalheim
1b836c9724
Merge pull request #22 from nix-community/raid2
...
add mdadm support
2022-08-24 19:20:53 +01:00
Jörg Thalheim
9bca66ca7d
Merge pull request #15 from nix-community/dev-disk
...
use /dev/disk/by-path for better nvme support
2022-08-23 19:39:46 +01:00
Jörg Thalheim
5bcd94a7ec
Merge pull request #12 from nix-community/flag-support
...
Add flag support
2022-08-19 08:52:50 +01:00
Jörg Thalheim
e97ddb5138
Merge pull request #11 from nix-community/change-mount-code
...
use findmnt and mount with X-mount.mkdir
2022-08-17 15:36:20 +01:00
Jörg Thalheim
f8522774e7
Merge pull request #10 from nix-community/docs
...
README: fix the example
2022-08-17 14:29:02 +01:00
Jörg Thalheim
91efad5326
Merge pull request #8 from nix-community/no-impure
...
No impure
2022-08-17 14:00:19 +01:00