This commit is contained in:
simono41 2017-11-11 03:54:36 +01:00
parent 0920c2304d
commit 3ee16435eb

View file

@ -299,6 +299,10 @@ if [ "${Partition}" == "gpt" ]; then
fi fi
if [ "${swap}" != "n" ]; then if [ "${swap}" != "n" ]; then
if [ "${verschluesselung}" == "y" ]; then
swappartition=$(blkid -s UUID -o value ${device}${swappartitionnummer})
echo "swap UUID=${swappartition} /dev/urandom swap,cipher=aes-cbc-essiv:sha256,size=256" >> ${mountpoint}/etc/crypttab
else
if [ "${Partition}" == "gpt" ]; then if [ "${Partition}" == "gpt" ]; then
swappartition=$(blkid -s PARTUUID -o value ${device}${swappartitionnummer}) swappartition=$(blkid -s PARTUUID -o value ${device}${swappartitionnummer})
echo "PARTUUID=${swappartition} none swap defaults 0 0" >> ${mountpoint}/etc/fstab echo "PARTUUID=${swappartition} none swap defaults 0 0" >> ${mountpoint}/etc/fstab
@ -307,6 +311,7 @@ if [ "${swap}" != "n" ]; then
echo "UUID=${swappartition} none swap defaults 0 0" >> ${mountpoint}/etc/fstab echo "UUID=${swappartition} none swap defaults 0 0" >> ${mountpoint}/etc/fstab
fi fi
fi fi
fi
#makeswapfile+fstab #makeswapfile+fstab
if [ "${swapfile}" == "y" ]; then if [ "${swapfile}" == "y" ]; then