summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--data/kernel_version1
-rwxr-xr-xdata/live-build-config/hooks/live/30-openvmtools-configs.chroot19
-rwxr-xr-xscripts/build-config5
-rwxr-xr-xscripts/build-submodules2
-rwxr-xr-xscripts/live-build-config2
5 files changed, 27 insertions, 2 deletions
diff --git a/data/kernel_version b/data/kernel_version
new file mode 100644
index 00000000..aca0bf9d
--- /dev/null
+++ b/data/kernel_version
@@ -0,0 +1 @@
+4.19.12
diff --git a/data/live-build-config/hooks/live/30-openvmtools-configs.chroot b/data/live-build-config/hooks/live/30-openvmtools-configs.chroot
new file mode 100755
index 00000000..545f40db
--- /dev/null
+++ b/data/live-build-config/hooks/live/30-openvmtools-configs.chroot
@@ -0,0 +1,19 @@
+#!/usr/bin/env python
+
+# The Cisco Unity plugin, that implements a proprietary extension
+# for IPsec split tunneling, interfers with DMVPN
+#
+# Since we do not do remote access IPsec, the simplest solution
+# is to disable it entirely from the start.
+
+import re
+
+vmtools_config = """
+[guestinfo]
+ poll-interval=0
+
+"""
+
+# Disable the 'cisco_unity' option in charon.conf
+with open('/etc/vmware-tools/tools.conf', 'w') as f:
+ f.write(vmtools_config)
diff --git a/scripts/build-config b/scripts/build-config
index 76e83192..3b44df77 100755
--- a/scripts/build-config
+++ b/scripts/build-config
@@ -125,6 +125,11 @@ env_check_retval = os.system("scripts/check-build-env")
if env_check_retval > 0:
print("Build environment check failed, fix the issues and retry")
+# Get the kernel version from data/kernel_version
+with open("data/kernel_version") as f:
+ kernel_version = f.read().strip()
+ args['kernel_version'] = kernel_version
+
# Save to file
os.makedirs(defaults.BUILD_DIR, exist_ok=True)
diff --git a/scripts/build-submodules b/scripts/build-submodules
index c89d4388..43568cfd 100755
--- a/scripts/build-submodules
+++ b/scripts/build-submodules
@@ -118,7 +118,7 @@ if [ -f "packages/vyos-kernel/Makefile" ]; then
PATCHLEVEL=$(grep "^PATCHLEVEL" Makefile | grep -Eo '[0-9]{1,4}')
SUBLEVEL=$(grep "^SUBLEVEL" Makefile | grep -Eo '[0-9]{1,4}')
ARCH=$(dpkg --print-architecture)
- sed -i.bak "s/--linux-packages .* \\\/--linux-packages linux-image-$VERSION\.$PATCHLEVEL\.$SUBLEVEL \\\/" $ROOTDIR/scripts/live-build-config
+ echo "$VERSION.$PATCHLEVEL.$SUBLEVEL" > $ROOTDIR/data/kernel_version
status_ok
fi
popd > /dev/null
diff --git a/scripts/live-build-config b/scripts/live-build-config
index 9dc03c32..b585049e 100755
--- a/scripts/live-build-config
+++ b/scripts/live-build-config
@@ -37,7 +37,7 @@ lb config noauto \
--architectures {{architecture}} \
--bootappend-live "boot=live components hostname=vyos username=live nopersistence noautologin nonetworking union=overlay" \
--linux-flavours {{architecture}}-vyos \
- --linux-packages linux-image-4.19.12 \
+ --linux-packages linux-image-{{kernel_version}} \
--bootloader syslinux,grub-efi \
--binary-images iso-hybrid \
--debian-installer false \