Create or remove decrypted mappings of encrypted volumes. Equivalent of
cryptsetup openandcryptsetup close. Arguments to this command are written exactly like a line in/etc/crypttab. It’s used by systemd to unlock devices on boot. See also:cryptsetup. More information: https://www.freedesktop.org/software/systemd/man/latest/systemd-cryptsetup.html.
/dev/mapper/mapping_name:systemd-cryptsetup attach {{mapping_name}} {{/dev/sdXY}}
/dev/mapper/mapping_name:systemd-cryptsetup attach {{mapping_name}} {{/dev/sdXY}} none {{crypttab_options}}
/dev/mapper/mapping_name:systemd-cryptsetup attach {{mapping_name}} {{/dev/sdXY}} {{path/to/keyfile}} {{crypttab_options}}
systemd-cryptsetup detach {{mapping_name}}