meta-digi-containers: set container runtime paths
Install the manager configuration with CC_CONTAINER_PATH as working_path. Move Podman graphroot under installed/podman and set lxc.lxcpath under installed/lxc for both LXC recipes. Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
This commit is contained in:
parent
804e5d5514
commit
9de4842dc3
|
|
@ -63,7 +63,7 @@ do_install() {
|
||||||
${D}${sysconfdir}/cc-container-mng.conf
|
${D}${sysconfdir}/cc-container-mng.conf
|
||||||
|
|
||||||
sed -i \
|
sed -i \
|
||||||
-e "s|\"/opt/cc-container|\"${CC_CONTAINER_PATH}|g" \
|
's|"working_path".*|"working_path": "${CC_CONTAINER_PATH}",|' \
|
||||||
${D}${sysconfdir}/cc-container-mng.conf
|
${D}${sysconfdir}/cc-container-mng.conf
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
do_install:append() {
|
do_install:append() {
|
||||||
if [ -f ${D}${sysconfdir}/containers/storage.conf ]; then
|
if [ -f ${D}${sysconfdir}/containers/storage.conf ]; then
|
||||||
sed -i 's|^graphroot = ".*"|graphroot = "${CC_CONTAINER_PATH}/storage"|' \
|
sed -i 's|^graphroot = ".*"|graphroot = "${CC_CONTAINER_PATH}/installed/podman"|' \
|
||||||
${D}${sysconfdir}/containers/storage.conf
|
${D}${sysconfdir}/containers/storage.conf
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,15 @@
|
||||||
|
# Copyright (C) 2026, Digi International Inc.
|
||||||
|
|
||||||
|
do_install:append() {
|
||||||
|
install -d ${D}${sysconfdir}/lxc
|
||||||
|
lxc_conf="${D}${sysconfdir}/lxc/lxc.conf"
|
||||||
|
touch "$lxc_conf"
|
||||||
|
|
||||||
|
if grep -q '^[[:space:]]*lxc\.lxcpath[[:space:]]*=' "$lxc_conf"; then
|
||||||
|
sed -i \
|
||||||
|
's|^[[:space:]]*lxc\.lxcpath[[:space:]]*=.*|lxc.lxcpath = ${CC_CONTAINER_PATH}/installed/lxc|' \
|
||||||
|
"$lxc_conf"
|
||||||
|
else
|
||||||
|
printf '%s\n' 'lxc.lxcpath = ${CC_CONTAINER_PATH}/installed/lxc' >> "$lxc_conf"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
@ -3,6 +3,7 @@
|
||||||
FILESEXTRAPATHS:prepend := "${COREBASE}/../meta-virtualization/recipes-containers/lxc/files:"
|
FILESEXTRAPATHS:prepend := "${COREBASE}/../meta-virtualization/recipes-containers/lxc/files:"
|
||||||
|
|
||||||
require recipes-containers/lxc/lxc_git.bb
|
require recipes-containers/lxc/lxc_git.bb
|
||||||
|
require recipes-containers/lxc/lxc-cc-container-path.inc
|
||||||
|
|
||||||
DESCRIPTION = "Trimmed LXC runtime for dey-image-containers"
|
DESCRIPTION = "Trimmed LXC runtime for dey-image-containers"
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,3 @@
|
||||||
|
# Copyright (C) 2026, Digi International Inc.
|
||||||
|
|
||||||
|
require recipes-containers/lxc/lxc-cc-container-path.inc
|
||||||
Loading…
Reference in New Issue