buildkit conmon and cri-dockerd fixes

pull/13762/head
Sharif Elgamal 2022-04-26 21:09:34 -07:00
parent f94644a153
commit a6a484534a
29 changed files with 100 additions and 5 deletions

View File

@ -293,9 +293,9 @@ minikube-iso-%: deploy/iso/minikube-iso/board/minikube/%/rootfs-overlay/usr/bin/
git clone --depth=1 --branch=$(BUILDROOT_BRANCH) https://github.com/buildroot/buildroot $(BUILD_DIR)/buildroot; \
cp deploy/iso/minikube-iso/go.hash $(BUILD_DIR)/buildroot/package/go/go.hash; \
fi;
$(MAKE) -C $(BUILD_DIR)/buildroot $(BUILDROOT_OPTIONS) O=$(BUILD_DIR)/buildroot/output-$* minikube_$*_defconfig
$(MAKE) -C $(BUILD_DIR)/buildroot $(BUILDROOT_OPTIONS) O=$(BUILD_DIR)/buildroot/output-$* host-python
$(MAKE) -C $(BUILD_DIR)/buildroot $(BUILDROOT_OPTIONS) O=$(BUILD_DIR)/buildroot/output-$*
$(MAKE) -C $(BUILD_DIR)/buildroot $(BUILDROOT_OPTIONS) GOARCH=$(subst x86_64,amd64,$(subst aarch64,arm64,$*)) O=$(BUILD_DIR)/buildroot/output-$* minikube_$*_defconfig
$(MAKE) -C $(BUILD_DIR)/buildroot $(BUILDROOT_OPTIONS) GOARCH=$(subst x86_64,amd64,$(subst aarch64,arm64,$*)) O=$(BUILD_DIR)/buildroot/output-$* host-python
$(MAKE) -C $(BUILD_DIR)/buildroot $(BUILDROOT_OPTIONS) GOARCH=$(subst x86_64,amd64,$(subst aarch64,arm64,$*)) O=$(BUILD_DIR)/buildroot/output-$*
mv $(BUILD_DIR)/buildroot/output-$*/images/boot.iso $(BUILD_DIR)/minikube-$(subst x86_64,amd64,$(subst aarch64,arm64,$*)).iso

View File

@ -1,4 +1,5 @@
menu "System tools"
source "$BR2_EXTERNAL_MINIKUBE_PATH/arch/aarch64/package/buildkit-bin-aarch64/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/arch/aarch64/package/runc-aarch64/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/arch/aarch64/package/crio-bin-aarch64/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/arch/aarch64/package/crictl-bin-aarch64/Config.in"

View File

@ -0,0 +1,4 @@
config BR2_PACKAGE_BUILDKIT_BIN
bool "buildkit-bin"
default y
depends on BR2_aarch64

View File

@ -0,0 +1 @@
0a834a749e86525e0eb16e7e80ce726e7c6a8e8d26fc5cc36c712305024da4e7 buildkit-v0.9.0.linux-arm64.tar.gz

View File

@ -0,0 +1,52 @@
################################################################################
#
# buildkit-bin
#
################################################################################
BUILDKIT_BIN_VERSION = v0.9.0
BUILDKIT_BIN_COMMIT = c8bb937807d405d92be91f06ce2629e6202ac7a9
BUILDKIT_BIN_SITE = https://github.com/moby/buildkit/releases/download/$(BUILDKIT_BIN_VERSION)
BUILDKIT_BIN_SOURCE = buildkit-$(BUILDKIT_BIN_VERSION).linux-arm64.tar.gz
# https://github.com/opencontainers/runc.git
BUILDKIT_RUNC_VERSION = 12644e614e25b05da6fd08a38ffa0cfe1903fdec
define BUILDKIT_BIN_USERS
- -1 buildkit -1 - - - - -
endef
define BUILDKIT_BIN_INSTALL_TARGET_CMDS
$(INSTALL) -D -m 0755 \
$(@D)/buildctl \
$(TARGET_DIR)/usr/bin
$(INSTALL) -D -m 0755 \
$(@D)/buildkit-runc \
$(TARGET_DIR)/usr/sbin
$(INSTALL) -D -m 0755 \
$(@D)/buildkit-qemu-* \
$(TARGET_DIR)/usr/sbin
$(INSTALL) -D -m 0755 \
$(@D)/buildkitd \
$(TARGET_DIR)/usr/sbin
$(INSTALL) -D -m 644 \
$(BUILDKIT_BIN_PKGDIR)/buildkit.conf \
$(TARGET_DIR)/usr/lib/tmpfiles.d/buildkit.conf
$(INSTALL) -D -m 644 \
$(BUILDKIT_BIN_PKGDIR)/buildkitd.toml \
$(TARGET_DIR)/etc/buildkit/buildkitd.toml
endef
define BUILDKIT_BIN_INSTALL_INIT_SYSTEMD
$(INSTALL) -D -m 644 \
$(BUILDKIT_BIN_PKGDIR)/buildkit.service \
$(TARGET_DIR)/usr/lib/systemd/system/buildkit.service
$(INSTALL) -D -m 644 \
$(BUILDKIT_BIN_PKGDIR)/buildkit.socket \
$(TARGET_DIR)/usr/lib/systemd/system/buildkit.socket
$(INSTALL) -D -m 644 \
$(BUILDKIT_BIN_PKGDIR)/51-buildkit.preset \
$(TARGET_DIR)/usr/lib/systemd/system-preset/51-buildkit.preset
endef
$(eval $(generic-package))

View File

@ -1,6 +1,7 @@
config BR2_PACKAGE_CRI_DOCKERD
bool "cri-dockerd"
default y
depends on BR2_aarch64
depends on BR2_PACKAGE_HOST_GO_TARGET_ARCH_SUPPORTS
depends on BR2_PACKAGE_HOST_GO_TARGET_CGO_LINKING_SUPPORTS
depends on BR2_TOOLCHAIN_HAS_THREADS

View File

@ -1,4 +1,6 @@
menu "System tools"
source "$BR2_EXTERNAL_MINIKUBE_PATH/arch/x86_64/package/conmon/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/arch/x86_64/package/buildkit-bin/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/arch/x86_64/package/runc-head/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/arch/x86_64/package/crio-bin/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/arch/x86_64/package/crictl-bin/Config.in"

View File

@ -0,0 +1 @@
disable buildkit.service

View File

@ -0,0 +1 @@
d /run/buildkit 0770 root buildkit

View File

@ -0,0 +1,11 @@
[Unit]
Description=BuildKit
Requires=buildkit.socket
After=buildkit.socket
Documentation=https://github.com/moby/buildkit
[Service]
ExecStart=/usr/sbin/buildkitd --addr fd://
[Install]
WantedBy=multi-user.target

View File

@ -0,0 +1,12 @@
[Unit]
Description=BuildKit
Documentation=https://github.com/moby/buildkit
[Socket]
ListenStream=%t/buildkit/buildkitd.sock
SocketMode=0660
SocketUser=root
SocketGroup=buildkit
[Install]
WantedBy=sockets.target

View File

@ -0,0 +1,5 @@
[worker.oci]
enabled = false
[worker.containerd]
enabled = true
namespace = "k8s.io"

View File

@ -1,5 +1,6 @@
config BR2_PACKAGE_CONMON
bool "conmon"
depends on BR2_x86_64
depends on BR2_PACKAGE_HOST_GO_TARGET_ARCH_SUPPORTS
depends on BR2_PACKAGE_HOST_GO_TARGET_CGO_LINKING_SUPPORTS
depends on BR2_TOOLCHAIN_HAS_THREADS

View File

@ -1,6 +1,7 @@
config BR2_PACKAGE_CRI_DOCKERD
bool "cri-dockerd"
default y
depends on BR2_x86_64
depends on BR2_PACKAGE_HOST_GO_TARGET_ARCH_SUPPORTS
depends on BR2_PACKAGE_HOST_GO_TARGET_CGO_LINKING_SUPPORTS
depends on BR2_TOOLCHAIN_HAS_THREADS

View File

@ -1,11 +1,9 @@
menu "System tools"
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/crun/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/conmon/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/automount/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/hyperv-daemons/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/gluster/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/vbox-guest/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/buildkit-bin/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/falco-module/Config.in"
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/scheduled-stop/Config.in"
endmenu

View File

@ -1,5 +1,6 @@
config BR2_PACKAGE_CRUN
bool "crun"
depends on BR2_x86_64
select BR2_PACKAGE_YAJL
help
A fast and low-memory footprint OCI Container Runtime

View File

@ -1,3 +1,4 @@
config BR2_PACKAGE_HYPERV_DAEMONS
bool "hyperv-daemons"
depends on BR2_x86_64
default y

View File

@ -1,3 +1,4 @@
config BR2_PACKAGE_SCHEDULED_STOP
bool "scheduled-stop"
depends on BR2_x86_64
default y

View File

@ -1,4 +1,5 @@
config BR2_PACKAGE_VBOX_GUEST
bool "vbox-guest"
depends on BR2_x86_64
depends on BR2_LINUX_KERNEL