<feed xmlns='http://www.w3.org/2005/Atom'>
<title>guix/gnu/system/mapped-devices.scm, branch master</title>
<subtitle>Transactional package manager, declarative GNU/Linux distribution, reproducible deployment tool, and more! https://guix.gnu.org</subtitle>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/'/>
<entry>
<title>guix: Ask LUKS password only once on boot when using GRUB.</title>
<updated>2026-04-09T17:55:05+00:00</updated>
<author>
<name>Danny Milosavljevic</name>
<email>dannym@friendly-machines.com</email>
</author>
<published>2026-02-08T20:50:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=b90597b98d46767207a0e92a84fb39c344472b69'/>
<id>b90597b98d46767207a0e92a84fb39c344472b69</id>
<content type='text'>
* gnu/bootloader/grub.scm (make-grub-configuration): Modify.
* gnu/system/mapped-devices.scm (open-luks-device): Modify.
* gnu/tests/install.scm (%encrypted-root-installation-script): Modify.
(%encrypted-root-os): Make debugging possible.
* doc/guix.texi (Mapped Devices): Cross-reference automatic LUKS master key
passing.
(BootloaderConfiguration): Document automatic LUKS master key passing via
GRUB's (proc)/luks_script.  Update extra-initrd documentation.

Change-Id: I5be74a524de04232d156e750109707fe7e50c28a
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* gnu/bootloader/grub.scm (make-grub-configuration): Modify.
* gnu/system/mapped-devices.scm (open-luks-device): Modify.
* gnu/tests/install.scm (%encrypted-root-installation-script): Modify.
(%encrypted-root-os): Make debugging possible.
* doc/guix.texi (Mapped Devices): Cross-reference automatic LUKS master key
passing.
(BootloaderConfiguration): Document automatic LUKS master key passing via
GRUB's (proc)/luks_script.  Update extra-initrd documentation.

Change-Id: I5be74a524de04232d156e750109707fe7e50c28a
</pre>
</div>
</content>
</entry>
<entry>
<title>mapped-devices/luks: Support extra options.</title>
<updated>2025-10-06T08:21:16+00:00</updated>
<author>
<name>45mg</name>
<email>45mg.writes@gmail.com</email>
</author>
<published>2025-09-22T13:12:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=73cbb94d1dd8a72405c023adeb89ab6940d0d82e'/>
<id>73cbb94d1dd8a72405c023adeb89ab6940d0d82e</id>
<content type='text'>
Allow passing extra options to the 'cryptsetup open' command.

* gnu/system/mapped-devices.scm (luks-device-mapping-with-options):
[#:extra-options]: New argument.
(open-luks-device): Use it.
(check-luks-device): Validate it.
* doc/guix.texi (Mapped Devices): Document it.
* gnu/tests/install.scm (%test-encrypted-root-extra-options-os): New
test for it, as well as the previously untested #:allow-discards?
option.
(%encrypted-root-extra-options-os): New os declaration for the test.

Change-Id: I265a431efb0c81ed7cfc984344c6b8a4cc2f1624
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Allow passing extra options to the 'cryptsetup open' command.

* gnu/system/mapped-devices.scm (luks-device-mapping-with-options):
[#:extra-options]: New argument.
(open-luks-device): Use it.
(check-luks-device): Validate it.
* doc/guix.texi (Mapped Devices): Document it.
* gnu/tests/install.scm (%test-encrypted-root-extra-options-os): New
test for it, as well as the previously untested #:allow-discards?
option.
(%encrypted-root-extra-options-os): New os declaration for the test.

Change-Id: I265a431efb0c81ed7cfc984344c6b8a4cc2f1624
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mapped-devices: luks: Adjust to support extra arguments.</title>
<updated>2025-07-17T22:57:31+00:00</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2025-07-06T14:54:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=14c8728f0d812ea2c396b3c0564fa8da1202f430'/>
<id>14c8728f0d812ea2c396b3c0564fa8da1202f430</id>
<content type='text'>
Fixes &lt;https://issues.guix.gnu.org/70826&gt;.

When using ‘luks-device-mapping-with-options’, procedures such as
‘operating-system-boot-mapped-devices’ would fail to identify LUKS
mapped devices because they would check whether the mapped device type
is ‘eq?’ to ‘luks-device-mapping’.

This addresses that by ensuring mapped devices are always of the
‘luks-device-mapping’ type, even when different options are used.

* gnu/system/mapped-devices.scm (close-luks-device): Add #:rest.
(luks-device-mapping-with-options): Deprecate.
* gnu/tests/install.scm (%encrypted-home-os-key-file): Update
accordingly.
* doc/guix.texi (Mapped Devices): Document use of the ‘arguments’ field
of ‘luks-device-mapping’.  Remove ‘luks-device-mapping-with-options’
documentation.
(Bootloader Configuration): Update example with key file in extra
initrd.

Change-Id: I5442908cb8ef4e3891dbb053cccf5e42b895486f
Reported-by: Tadhg McDonald-Jensen &lt;tadhgmister@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fixes &lt;https://issues.guix.gnu.org/70826&gt;.

When using ‘luks-device-mapping-with-options’, procedures such as
‘operating-system-boot-mapped-devices’ would fail to identify LUKS
mapped devices because they would check whether the mapped device type
is ‘eq?’ to ‘luks-device-mapping’.

This addresses that by ensuring mapped devices are always of the
‘luks-device-mapping’ type, even when different options are used.

* gnu/system/mapped-devices.scm (close-luks-device): Add #:rest.
(luks-device-mapping-with-options): Deprecate.
* gnu/tests/install.scm (%encrypted-home-os-key-file): Update
accordingly.
* doc/guix.texi (Mapped Devices): Document use of the ‘arguments’ field
of ‘luks-device-mapping’.  Remove ‘luks-device-mapping-with-options’
documentation.
(Bootloader Configuration): Update example with key file in extra
initrd.

Change-Id: I5442908cb8ef4e3891dbb053cccf5e42b895486f
Reported-by: Tadhg McDonald-Jensen &lt;tadhgmister@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mapped-devices: Add ‘arguments’ field.</title>
<updated>2025-07-17T22:57:25+00:00</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2025-07-06T14:31:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=62bf9a7cc79d24e7edc2b56d6dde6e77eebc537e'/>
<id>62bf9a7cc79d24e7edc2b56d6dde6e77eebc537e</id>
<content type='text'>
Fixes &lt;https://issues.guix.gnu.org/70826&gt;.

This allows users to specify extra arguments specific to the underlying
mapped device type.

* gnu/system/mapped-devices.scm (&lt;mapped-device&gt;)[arguments]: New field.
(device-mapping-service-type): Honor it.
* guix/scripts/system.scm (check-mapped-devices): Likewise.
* gnu/system/linux-initrd.scm (raw-initrd): Likewise.
* doc/guix.texi (Mapped Devices): Document it.

Reported-by: 45mg &lt;45mg.writes@gmail.com&gt;
Change-Id: Idef5a3e68535c412f13bae9a92c81c49053d4f4a
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fixes &lt;https://issues.guix.gnu.org/70826&gt;.

This allows users to specify extra arguments specific to the underlying
mapped device type.

* gnu/system/mapped-devices.scm (&lt;mapped-device&gt;)[arguments]: New field.
(device-mapping-service-type): Honor it.
* guix/scripts/system.scm (check-mapped-devices): Likewise.
* gnu/system/linux-initrd.scm (raw-initrd): Likewise.
* doc/guix.texi (Mapped Devices): Document it.

Reported-by: 45mg &lt;45mg.writes@gmail.com&gt;
Change-Id: Idef5a3e68535c412f13bae9a92c81c49053d4f4a
</pre>
</div>
</content>
</entry>
<entry>
<title>mapped-devices/luks: Add support for --allow-discards.</title>
<updated>2025-03-22T13:53:13+00:00</updated>
<author>
<name>Sören Tempel</name>
<email>soeren@soeren-tempel.net</email>
</author>
<published>2025-03-16T11:49:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=7aa855b05be97087b87e01fb3bc1fd48109bbf7c'/>
<id>7aa855b05be97087b87e01fb3bc1fd48109bbf7c</id>
<content type='text'>
* gnu/system/mapped-devices.scm (open-luks-device): Support opening
LUKS devices with the --allow-discards option.
* gnu/system/mapped-devices.scm (luks-device-mapping-with-options):
Pass through the allow-discards? keyword argument.
* doc/guix.texi (Mapped Devices): Update documentation for the
luks-device-mapping-with-options procedure.

Co-authored-by: Sisiutl &lt;sisiutl@egregore.fun&gt;
Modified-by: Maxim Cournoyer &lt;maxim.cournoyer@gmail.com&gt;
Change-Id: Iff82d7d548486f028d19f6aa35dd30ca194f57cc
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* gnu/system/mapped-devices.scm (open-luks-device): Support opening
LUKS devices with the --allow-discards option.
* gnu/system/mapped-devices.scm (luks-device-mapping-with-options):
Pass through the allow-discards? keyword argument.
* doc/guix.texi (Mapped Devices): Update documentation for the
luks-device-mapping-with-options procedure.

Co-authored-by: Sisiutl &lt;sisiutl@egregore.fun&gt;
Modified-by: Maxim Cournoyer &lt;maxim.cournoyer@gmail.com&gt;
Change-Id: Iff82d7d548486f028d19f6aa35dd30ca194f57cc
</pre>
</div>
</content>
</entry>
<entry>
<title>mapped-devices: lvm: Add missing module import.</title>
<updated>2024-05-27T17:30:22+00:00</updated>
<author>
<name>Lars-Dominik Braun</name>
<email>lars@6xq.net</email>
</author>
<published>2024-05-26T14:32:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=ed5bf620ea6366d8468e5b7dad9874c6e0e8c661'/>
<id>ed5bf620ea6366d8468e5b7dad9874c6e0e8c661</id>
<content type='text'>
Tested with (locally fixed) lvm-separate-home-os system test.

* gnu/system/mapped-devices.scm (lvm-device-mapping): Add SRFI-1 to
modules.

Change-Id: I8c155b47c29004bdc59057391dfba94ce33bdbc2
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Tested with (locally fixed) lvm-separate-home-os system test.

* gnu/system/mapped-devices.scm (lvm-device-mapping): Add SRFI-1 to
modules.

Change-Id: I8c155b47c29004bdc59057391dfba94ce33bdbc2
</pre>
</div>
</content>
</entry>
<entry>
<title>mapped-devices: luks: Specify modules needed at the top-level.</title>
<updated>2024-04-07T22:17:57+00:00</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2024-04-07T22:15:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=49f82fca4130ffcfb16aa0cf89750ab56fb99ad7'/>
<id>49f82fca4130ffcfb16aa0cf89750ab56fb99ad7</id>
<content type='text'>
Fixes &lt;https://issues.guix.gnu.org/70266&gt;.

* gnu/system/mapped-devices.scm (luks-device-mapping)[modules]: New
field.
(open-luks-device): Remove non-top-level ‘use-modules’ form.
* gnu/system/linux-initrd.scm (raw-initrd): Remove modules that were
added specifically for ‘luks-device-mapping’.

Change-Id: I4253c3dd5e3cbcee41ec84fd57227abd428d1bd6
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fixes &lt;https://issues.guix.gnu.org/70266&gt;.

* gnu/system/mapped-devices.scm (luks-device-mapping)[modules]: New
field.
(open-luks-device): Remove non-top-level ‘use-modules’ form.
* gnu/system/linux-initrd.scm (raw-initrd): Remove modules that were
added specifically for ‘luks-device-mapping’.

Change-Id: I4253c3dd5e3cbcee41ec84fd57227abd428d1bd6
</pre>
</div>
</content>
</entry>
<entry>
<title>mapped-devices: &lt;mapped-device-type&gt; can specify modules to import.</title>
<updated>2024-04-07T22:13:25+00:00</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2024-04-07T22:13:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=6062339156ecc42cac59af0d34e22fcc7da3aa4a'/>
<id>6062339156ecc42cac59af0d34e22fcc7da3aa4a</id>
<content type='text'>
* gnu/system/mapped-devices.scm (&lt;mapped-device-type&gt;)[modules]: New
field.
(device-mapping-service-type): Honor it.
* gnu/system/linux-initrd.scm (raw-initrd): Likewise.

Change-Id: Icc702cb6f281741975e33203f87fbc1ffa9856da
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* gnu/system/mapped-devices.scm (&lt;mapped-device-type&gt;)[modules]: New
field.
(device-mapping-service-type): Honor it.
* gnu/system/linux-initrd.scm (raw-initrd): Likewise.

Change-Id: Icc702cb6f281741975e33203f87fbc1ffa9856da
</pre>
</div>
</content>
</entry>
<entry>
<title>mapped-devices: Allow unlocking by a key file.</title>
<updated>2024-01-14T22:00:03+00:00</updated>
<author>
<name>Tomas Volf</name>
<email>wolf@wolfsden.cz</email>
</author>
<published>2024-01-11T17:35:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=d082312ef7adfea69c79d30ef947817b39832161'/>
<id>d082312ef7adfea69c79d30ef947817b39832161</id>
<content type='text'>
Requiring the user to input their password in order to unlock a device is not
always reasonable, so having an option to unlock the device using a key file
is a nice quality of life change.

* gnu/system/mapped-devices.scm (open-luks-device): Add #:key-file argument.
(luks-device-mapping-with-options): New procedure.
* doc/guix.texi (Mapped Devices): Describe the new procedure.

Change-Id: I1de4e045f8c2c11f9a94f1656e839c785b0c11c4
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Requiring the user to input their password in order to unlock a device is not
always reasonable, so having an option to unlock the device using a key file
is a nice quality of life change.

* gnu/system/mapped-devices.scm (open-luks-device): Add #:key-file argument.
(luks-device-mapping-with-options): New procedure.
* doc/guix.texi (Mapped Devices): Describe the new procedure.

Change-Id: I1de4e045f8c2c11f9a94f1656e839c785b0c11c4
Signed-off-by: Ludovic Courtès &lt;ludo@gnu.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mapped-devices: Ensure 'cryptsetup open' gets a tty.</title>
<updated>2022-04-08T16:14:35+00:00</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2022-04-08T09:53:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.vineetk.net/guix/commit/?id=931f13840bad7bd3cb98b7806f09ca2b3cf7cd10'/>
<id>931f13840bad7bd3cb98b7806f09ca2b3cf7cd10</id>
<content type='text'>
Fixes &lt;https://issues.guix.gnu.org/54770&gt;.
Regression introduced in 400c9ed3d779308e56038305d40cd93acb496180.

Previously, for an encrypted /home (say), "cryptsetup open" would be
invoked by shepherd, with /dev/null as its standard input.  It would
thus run in non-interactive mode and, instead of asking for a
passphrase, fail with:

  Nothing to read on input.

This change ensures it runs in interactive mode.

* gnu/build/file-systems.scm (system*/console, system*/tty): New
procedures.
* gnu/system/mapped-devices.scm (open-luks-device): Use 'system*/tty'
instead of 'system*'.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fixes &lt;https://issues.guix.gnu.org/54770&gt;.
Regression introduced in 400c9ed3d779308e56038305d40cd93acb496180.

Previously, for an encrypted /home (say), "cryptsetup open" would be
invoked by shepherd, with /dev/null as its standard input.  It would
thus run in non-interactive mode and, instead of asking for a
passphrase, fail with:

  Nothing to read on input.

This change ensures it runs in interactive mode.

* gnu/build/file-systems.scm (system*/console, system*/tty): New
procedures.
* gnu/system/mapped-devices.scm (open-luks-device): Use 'system*/tty'
instead of 'system*'.
</pre>
</div>
</content>
</entry>
</feed>
