1
0
mirror of https://github.com/home-assistant/operating-system.git synced 2026-02-15 07:29:08 +00:00

Use matching version of DinD daemon when creating hassio data partition (#4344)

Use the version used in the docker-engine package to ensure it stays in sync.
Although we haven't seen any issues related to the fact it was sometimes
mismatching, reduce the burden of needing it to be synced manually.
This commit is contained in:
Jan Čermák
2025-10-10 10:50:25 +02:00
committed by GitHub
parent 2e48a0a586
commit daa6a7c868
2 changed files with 4 additions and 4 deletions

View File

@@ -4,6 +4,7 @@ set -e
build_dir=$1
dst_dir=$2
channel=$3
docker_version=$4
data_img="${dst_dir}/data.ext4"
@@ -17,13 +18,12 @@ mkdir -p "${build_dir}/data/"
sudo mount -o loop,discard "${data_img}" "${build_dir}/data/"
# Use official Docker in Docker images
# Ideally we use the same version as Buildroot is using in case the
# overlayfs2 storage format changes
# We use the same version as Buildroot is using to ensure best compatibility
container=$(docker run --privileged -e DOCKER_TLS_CERTDIR="" \
-v "${build_dir}/data/":/data \
-v "${build_dir}/data/docker/":/var/lib/docker \
-v "${build_dir}":/build \
-d docker:28.0-dind --storage-driver overlay2)
-d "docker:${docker_version}-dind" --storage-driver overlay2)
docker exec "${container}" sh /build/dind-import-containers.sh "${channel}"

View File

@@ -37,7 +37,7 @@ endef
HASSIO_INSTALL_IMAGES = YES
define HASSIO_INSTALL_IMAGES_CMDS
$(BR2_EXTERNAL_HASSOS_PATH)/package/hassio/create-data-partition.sh "$(@D)" "$(BINARIES_DIR)" "$(HASSIO_VERSION_CHANNEL)"
$(BR2_EXTERNAL_HASSOS_PATH)/package/hassio/create-data-partition.sh "$(@D)" "$(BINARIES_DIR)" "$(HASSIO_VERSION_CHANNEL)" "$(DOCKER_ENGINE_VERSION)"
endef
$(eval $(generic-package))