mirror of
https://github.com/linuxkit/linuxkit.git
synced 2026-04-08 10:22:05 +00:00
projects: add kernel-config project
This is just a direct import of the current kernel/ directory, with a slight splitting up of the dockerfiles to build a kernel-source and kernel image. Signed-off-by: Tycho Andersen <tycho@docker.com>
This commit is contained in:
18
projects/kernel-config/Dockerfile.source
Normal file
18
projects/kernel-config/Dockerfile.source
Normal file
@@ -0,0 +1,18 @@
|
||||
FROM linuxkit/kernel-compile:1b396c221af673757703258159ddc8539843b02b@sha256:6b32d205bfc6407568324337b707d195d027328dbfec554428ea93e7b0a8299b AS kernel-build
|
||||
|
||||
ARG KERNEL_VERSION
|
||||
ARG KERNEL_SERIES
|
||||
|
||||
ENV KERNEL_SOURCE=https://www.kernel.org/pub/linux/kernel/v4.x/linux-${KERNEL_VERSION}.tar.xz
|
||||
|
||||
RUN curl -fsSL -o linux-${KERNEL_VERSION}.tar.xz ${KERNEL_SOURCE}
|
||||
|
||||
RUN cat linux-${KERNEL_VERSION}.tar.xz | tar --absolute-names -xJ && mv /linux-${KERNEL_VERSION} /linux
|
||||
|
||||
# Apply local patches
|
||||
COPY patches-${KERNEL_SERIES} /patches
|
||||
WORKDIR /linux
|
||||
RUN set -e && for patch in /patches/*.patch; do \
|
||||
echo "Applying $patch"; \
|
||||
patch -p1 < "$patch"; \
|
||||
done
|
||||
Reference in New Issue
Block a user