Created
April 24, 2020 12:38
-
-
Save aegiap/97d7f3f69dfde60fb8244d8b1125d423 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- /usr/share/gandi/bootstrap.d/01-config_swap.orig 2020-04-24 14:37:36.210057319 +0200 | |
+++ /usr/share/gandi/bootstrap.d/01-config_swap 2020-04-24 14:37:50.618311531 +0200 | |
@@ -185,17 +185,17 @@ | |
# if the swap device is already activated, we stop there | |
/sbin/swapon -s | grep -q "^$swap_device " && exit 0 | |
-# We read the files for the configuration from the disk and not | |
-# the swap partition. | |
-# If a valid tar archive extracts with no error at offset 4k*128, | |
-# use it. Otherwise continue with swap creation logic. | |
-if dd if="${full_device}" bs=4k skip=128 2> /dev/null | tar t gandi 2> /dev/null > /dev/null; then | |
- setup_in_swap "${swap_device}" "${full_device}" | |
-else | |
- msg='Cannot find tarball and info in the swap space. Continue formatting.' | |
- echo "$msg" | logger -t gandi | |
- echo "$msg" | |
-fi | |
+## We read the files for the configuration from the disk and not | |
+## the swap partition. | |
+## If a valid tar archive extracts with no error at offset 4k*128, | |
+## use it. Otherwise continue with swap creation logic. | |
+#if dd if="${full_device}" bs=4k skip=128 2> /dev/null | tar t gandi 2> /dev/null > /dev/null; then | |
+# setup_in_swap "${swap_device}" "${full_device}" | |
+#else | |
+# msg='Cannot find tarball and info in the swap space. Continue formatting.' | |
+# echo "$msg" | logger -t gandi | |
+# echo "$msg" | |
+#fi | |
if [ -x /sbin/blkid ]; then | |
detect_blkid "$swap_device" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment