Commit cab92ee0 authored by Raphaël Hertzog's avatar Raphaël Hertzog

Force-enable cryptsetup in the initramfs

parent 893bc5aa
......@@ -10,6 +10,17 @@ fi
# See
systemctl --user enable pulseaudio.service || true
# Enable cryptsetup in the initramfs for later use if the user
# adds an encrypted persistence partition.
# This is until has a proper fix.
if [ -e /etc/cryptsetup-initramfs/conf-hook ]; then
if grep -q '^#CRYPTSETUP=' /etc/cryptsetup-initramfs/conf-hook; then
sed -i -e 's/^#CRYPTSETUP=.*/CRYPTSETUP=y/' /etc/cryptsetup-initramfs/conf-hook
echo "CRYPTSETUP=y" >>/etc/cryptsetup-initramfs/conf-hook
# Disable the udev rules renaming the network interfaces (can also be
# achieved with kernel command line net.ifnames=0 but we don't have a nice
# way to set it on the installed system)
......@@ -17,6 +28,9 @@ mkdir -p /etc/systemd/network /etc/udev/rules.d
ln -sf /dev/null /etc/systemd/network/
ln -sf /dev/null /etc/systemd/network/
echo > /etc/udev/rules.d/73-special-net-names.rules
# Rebuild the initramfs to include the last two changes (cryptsetup,
# network device)
update-initramfs -u
# Run updatedb to initialize the database for the locate command
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment