mirror of
https://github.com/terem42/zfs-hetzner-vm.git
synced 2025-12-23 23:38:38 +00:00
cryptsetup
This commit is contained in:
@@ -771,8 +771,7 @@ if [[ $v_encrypt_rpool == "1" ]]; then
|
||||
echo "=========set up dropbear=============="
|
||||
|
||||
chroot_execute "apt install --yes dropbear-initramfs"
|
||||
chroot_execute "apt purge cryptsetup-initramfs --yes"
|
||||
|
||||
|
||||
mkdir -p "$c_zfs_mount_dir/etc/dropbear-initramfs"
|
||||
cp /root/.ssh/authorized_keys "$c_zfs_mount_dir/etc/dropbear-initramfs/authorized_keys"
|
||||
|
||||
@@ -800,6 +799,7 @@ CONF
|
||||
|
||||
echo "========running packages upgrade==========="
|
||||
chroot_execute "apt upgrade --yes"
|
||||
chroot_execute "apt purge cryptsetup-initramfs --yes"
|
||||
|
||||
echo "===========add static route to initramfs via hook to add default routes for Hetzner due to Debian/Ubuntu initramfs DHCP bug ========="
|
||||
mkdir -p "$c_zfs_mount_dir/usr/share/initramfs-tools/scripts/init-premount"
|
||||
@@ -827,17 +827,17 @@ ip route add 172.31.1.1/255.255.255.255 dev eth0
|
||||
ip route add default via 172.31.1.1 dev eth0
|
||||
CONF
|
||||
|
||||
cat > "$c_zfs_mount_dir/etc/network/interfaces" <<'CONF'
|
||||
auto lo
|
||||
iface lo inet loopback
|
||||
iface lo inet6 loopback
|
||||
#cat > "$c_zfs_mount_dir/etc/network/interfaces" <<'CONF'
|
||||
#auto lo
|
||||
#iface lo inet loopback
|
||||
#iface lo inet6 loopback
|
||||
|
||||
allow-hotplug eth0
|
||||
iface eth0 inet dhcp
|
||||
iface eth0 inet6 dhcp
|
||||
CONF
|
||||
#allow-hotplug eth0
|
||||
#iface eth0 inet dhcp
|
||||
#iface eth0 inet6 dhcp
|
||||
#CONF
|
||||
|
||||
chmod 755 "$c_zfs_mount_dir/etc/network/interfaces"
|
||||
#chmod 755 "$c_zfs_mount_dir/etc/network/interfaces"
|
||||
|
||||
echo "======= update initramfs =========="
|
||||
chroot_execute "update-initramfs -u -k all"
|
||||
|
||||
Reference in New Issue
Block a user