mirror of
https://github.com/systemd/systemd.git
synced 2024-12-26 03:22:00 +03:00
7a17e41dcf
(The one case that is left unchanged is '< <(subcommand)'.) This way, the style with no gap was already dominant. This way, the reader immediately knows that ' < ' is a comparison operator and ' << ' is a shift. In a few cases, replace custom EOF replacement by just EOF. There is no point in using someting like "_EOL" unless "EOF" appears in the text.
13 lines
560 B
Bash
13 lines
560 B
Bash
# SPDX-License-Identifier: MIT-0
|
|
|
|
# Enroll the TPM2 security chip in the LUKS2 volume, and bind it to PCR 7
|
|
# only. Replace /dev/sdXn by the partition to use (e.g. /dev/sda1).
|
|
sudo systemd-cryptenroll --tpm2-device=auto --tpm2-pcrs=7 /dev/sdXn
|
|
|
|
# Test: Let's run systemd-cryptsetup to test if this worked.
|
|
sudo /usr/lib/systemd/systemd-cryptsetup attach mytest /dev/sdXn - tpm2-device=auto
|
|
|
|
# If that worked, let's now add the same line persistently to /etc/crypttab,
|
|
# for the future.
|
|
sudo bash -c 'echo "mytest /dev/sdXn - tpm2-device=auto" >>/etc/crypttab'
|