diff --git a/Dockerfile b/Dockerfile index d164f3f6..d580b83e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -44,7 +44,8 @@ RUN git clone https://github.com/amnezia-vpn/amneziawg-linux-kernel-module.git # Build the kernel module WORKDIR /build/amneziawg-linux-kernel-module/src -RUN make KERNELDIR="/usr/src/linux-headers-lts" || \ +RUN KERNEL_VERSION=$(cat /build/kernel_version.txt) && \ + make KERNELDIR="/usr/src/linux-headers-${KERNEL_VERSION}-0-lts" || \ echo "Kernel module build failed, will use userspace fallback" # Prepare module for installation