diff options
| -rw-r--r-- | conf/distro/include/meta-virt-container.inc | 10 | ||||
| -rw-r--r-- | recipes-extended/images/container-image-host.bb | 3 |
2 files changed, 11 insertions, 2 deletions
diff --git a/conf/distro/include/meta-virt-container.inc b/conf/distro/include/meta-virt-container.inc index d3e91eef..6472d855 100644 --- a/conf/distro/include/meta-virt-container.inc +++ b/conf/distro/include/meta-virt-container.inc | |||
| @@ -40,3 +40,13 @@ | |||
| 40 | 40 | ||
| 41 | CONTAINER_RO_REMOVE ?= " ${@bb.utils.contains('VIRTUAL-RUNTIME_container_engine', 'podman', 'shadow', '', d)}" | 41 | CONTAINER_RO_REMOVE ?= " ${@bb.utils.contains('VIRTUAL-RUNTIME_container_engine', 'podman', 'shadow', '', d)}" |
| 42 | ROOTFS_RO_UNNEEDED:remove = "${CONTAINER_RO_REMOVE}" | 42 | ROOTFS_RO_UNNEEDED:remove = "${CONTAINER_RO_REMOVE}" |
| 43 | |||
| 44 | # Container registry IMAGE_FEATURES support. | ||
| 45 | # Defining FEATURE_PACKAGES_container-registry globally makes | ||
| 46 | # "container-registry" a valid IMAGE_FEATURES value for any image | ||
| 47 | # recipe (image.bbclass check_image_features auto-discovers | ||
| 48 | # FEATURE_PACKAGES_* variables). This avoids IMAGE_FEATURES[validitems] | ||
| 49 | # which pollutes signatures when set globally. | ||
| 50 | # Default is empty (validation only); container-image-host.bb sets the | ||
| 51 | # actual packages. | ||
| 52 | FEATURE_PACKAGES_container-registry ?= "" | ||
diff --git a/recipes-extended/images/container-image-host.bb b/recipes-extended/images/container-image-host.bb index 723f0cf5..596b62e0 100644 --- a/recipes-extended/images/container-image-host.bb +++ b/recipes-extended/images/container-image-host.bb | |||
| @@ -84,10 +84,9 @@ REQUIRED_DISTRO_FEATURES:append = " ${@bb.utils.contains('VIRTUAL-RUNTIME_contai | |||
| 84 | # of the host name to make it unique | 84 | # of the host name to make it unique |
| 85 | IMAGE_FEATURES[validitems] += "virt-unique-hostname" | 85 | IMAGE_FEATURES[validitems] += "virt-unique-hostname" |
| 86 | IMAGE_FEATURES[validitems] += "container-tools" | 86 | IMAGE_FEATURES[validitems] += "container-tools" |
| 87 | IMAGE_FEATURES[validitems] += "container-registry" | ||
| 88 | |||
| 89 | # Container registry configuration packages (opt-in via IMAGE_FEATURES += "container-registry") | 87 | # Container registry configuration packages (opt-in via IMAGE_FEATURES += "container-registry") |
| 90 | # Requires CONTAINER_REGISTRY_URL and/or DOCKER_REGISTRY_INSECURE to be set | 88 | # Requires CONTAINER_REGISTRY_URL and/or DOCKER_REGISTRY_INSECURE to be set |
| 89 | # (overrides empty default from meta-virt-container.inc) | ||
| 91 | FEATURE_PACKAGES_container-registry = "\ | 90 | FEATURE_PACKAGES_container-registry = "\ |
| 92 | ${@bb.utils.contains_any('VIRTUAL-RUNTIME_container_engine', 'docker docker-moby', 'docker-registry-config', '', d)} \ | 91 | ${@bb.utils.contains_any('VIRTUAL-RUNTIME_container_engine', 'docker docker-moby', 'docker-registry-config', '', d)} \ |
| 93 | ${@bb.utils.contains_any('VIRTUAL-RUNTIME_container_engine', 'podman containerd cri-o', 'container-oci-registry-config', '', d)} \ | 92 | ${@bb.utils.contains_any('VIRTUAL-RUNTIME_container_engine', 'podman containerd cri-o', 'container-oci-registry-config', '', d)} \ |
