mirror of
git://git.yoctoproject.org/meta-virtualization.git
synced 2025-07-19 12:50:22 +02:00
images: add reference application container
Includes container-base. Provides an application container that installs a package (or packages) to the container and make the specified command the OCI_IMAGE_ENTRYPOINT. CONTAINER_APP_CMD : the binary to run via the OCI_IMAGE_ENTRYPOINT CONATINER_APP: packages to install to the container The default entry point is the "date" command. % root@qemuarm64-54:~# docker run zeddii/container-app-base Mon Oct 28 18:41:23 UTC 2024 % root@qemuarm64-54:~# docker run --entrypoint "du" zeddii/container-app-base -sh 2.6M . % podman run docker.io/zeddii/container-app-base Mon Oct 28 18:41:23 UTC 2024 Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
This commit is contained in:
parent
683e03c275
commit
30647f3d94
17
recipes-extended/images/container-app-base.bb
Normal file
17
recipes-extended/images/container-app-base.bb
Normal file
|
@ -0,0 +1,17 @@
|
|||
SUMMARY = "Basic Application container image"
|
||||
LICENSE = "MIT"
|
||||
LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
|
||||
|
||||
include container-base.bb
|
||||
|
||||
# CONTAINER_APP_CMD is the executable to run as the entrypoint of the
|
||||
# container. What we have below is a placholder. if you run this
|
||||
# container, you'll get the date echo'd
|
||||
CONTAINER_APP_CMD ?= "date"
|
||||
|
||||
# The container app is the package(s) to install into the container.
|
||||
# They must provide the command specified in CONTAINER_APP_CMD
|
||||
CONTAINER_APP ?= ""
|
||||
|
||||
OCI_IMAGE_ENTRYPOINT = "${CONTAINER_APP_CMD}"
|
||||
IMAGE_INSTALL:append = "${CONTAINER_APP}"
|
Loading…
Reference in New Issue
Block a user