mirror of
https://github.com/linuxkit/linuxkit.git
synced 2025-07-19 09:16:29 +00:00
Merge pull request #4011 from deitch/kernel-push-builder
Kernel push builder
This commit is contained in:
commit
0d89422386
@ -36,19 +36,14 @@ endif
|
||||
|
||||
REPO_ROOT:=$(shell git rev-parse --show-toplevel)
|
||||
|
||||
# Path to push-manifest.sh
|
||||
PUSH_MANIFEST:=$(REPO_ROOT)/scripts/push-manifest.sh
|
||||
|
||||
# determine our architecture
|
||||
BUILDERARCH=
|
||||
ifneq ($(ARCH),)
|
||||
ifeq ($(ARCH),$(filter $(ARCH),x86_64 amd64))
|
||||
SUFFIX=-amd64
|
||||
override ARCH=x86_64
|
||||
BUILDERARCH=amd64
|
||||
endif
|
||||
ifeq ($(ARCH),$(filter $(ARCH),aarch64 arm64))
|
||||
SUFFIX=-arm64
|
||||
override ARCH=aarch64
|
||||
BUILDERARCH=arm64
|
||||
endif
|
||||
@ -137,11 +132,13 @@ builddebugkernel-%: buildkerneldeps-%
|
||||
|
||||
push-%: notdirty build-% pushkernel-% tagbuilder-% pushtools-%;
|
||||
|
||||
# tagbuilder-% tags the builder image with the kernel version and `-builder` and pushes it
|
||||
# checks if it already matches on the registry before pushing
|
||||
# because the build may have been on a remote builder, or we may not have had to do a local build,
|
||||
# we cannot assume that IMAGE_BUILDER is available locally, whether in docker image cache or limuxkit cache
|
||||
tagbuilder-%: notdirty
|
||||
$(eval BUILDER_IMAGE=$(call baseimage,$*)-builder)
|
||||
docker tag $(IMAGE_BUILDER) $(BUILDER_IMAGE)$(SUFFIX) && \
|
||||
docker push $(BUILDER_IMAGE)$(SUFFIX) && \
|
||||
$(PUSH_MANIFEST) $(BUILDER_IMAGE)
|
||||
linuxkit pkg remote-tag $(IMAGE_BUILDER) $(BUILDER_IMAGE)
|
||||
|
||||
pushkernel-%: pushplainkernel-% pushdebugkernel-%;
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
kernel:
|
||||
image: linuxkit/kernel:6.6.13-ad4d0da9e582d714cf61c8d99468cc7c1109bce5
|
||||
image: linuxkit/kernel:6.6.13-e274bc71d6552570c922d2fca6c6481d1f9f045a
|
||||
cmdline: "console=ttyS0 console=ttyAMA0"
|
||||
init:
|
||||
- linuxkit/init:07d37c3ae7fad5ddcb54c8dc65774ae050851f04
|
||||
|
@ -3,7 +3,7 @@
|
||||
# In the last stage, it creates a package, which can be used for
|
||||
# testing.
|
||||
|
||||
FROM linuxkit/kernel:6.6.13-ad4d0da9e582d714cf61c8d99468cc7c1109bce5 AS ksrc
|
||||
FROM linuxkit/kernel:6.6.13-e274bc71d6552570c922d2fca6c6481d1f9f045a AS ksrc
|
||||
|
||||
# Extract headers and compile module
|
||||
FROM linuxkit/kernel:6.6.13-builder AS build
|
||||
|
@ -1,5 +1,5 @@
|
||||
kernel:
|
||||
image: linuxkit/kernel:6.6.13-ad4d0da9e582d714cf61c8d99468cc7c1109bce5
|
||||
image: linuxkit/kernel:6.6.13-e274bc71d6552570c922d2fca6c6481d1f9f045a
|
||||
cmdline: "console=ttyS0 console=ttyAMA0"
|
||||
init:
|
||||
- linuxkit/init:07d37c3ae7fad5ddcb54c8dc65774ae050851f04
|
||||
|
Loading…
Reference in New Issue
Block a user