diff options
| -rw-r--r-- | recipes-demo/images/app-container-curl.bb | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/recipes-demo/images/app-container-curl.bb b/recipes-demo/images/app-container-curl.bb new file mode 100644 index 00000000..51451300 --- /dev/null +++ b/recipes-demo/images/app-container-curl.bb | |||
| @@ -0,0 +1,46 @@ | |||
| 1 | SUMMARY = "Curl Application container image" | ||
| 2 | LICENSE = "MIT" | ||
| 3 | LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420" | ||
| 4 | |||
| 5 | IMAGE_FSTYPES = "container oci" | ||
| 6 | inherit image | ||
| 7 | inherit image-oci | ||
| 8 | |||
| 9 | IMAGE_FEATURES = "" | ||
| 10 | IMAGE_LINGUAS = "" | ||
| 11 | NO_RECOMMENDATIONS = "1" | ||
| 12 | |||
| 13 | IMAGE_INSTALL = " \ | ||
| 14 | base-files \ | ||
| 15 | base-passwd \ | ||
| 16 | netbase \ | ||
| 17 | ${CONTAINER_SHELL} \ | ||
| 18 | " | ||
| 19 | |||
| 20 | # If the following is configured in local.conf (or the distro): | ||
| 21 | # PACKAGE_EXTRA_ARCHS:append = " container-dummy-provides" | ||
| 22 | # | ||
| 23 | # it has been explicitly # indicated that we don't want or need a shell, so we'll | ||
| 24 | # add the dummy provides. | ||
| 25 | # | ||
| 26 | # This is required, since there are postinstall scripts in base-files and base-passwd | ||
| 27 | # that reference /bin/sh and we'll get a rootfs error if there's no shell or no dummy | ||
| 28 | # provider. | ||
| 29 | CONTAINER_SHELL ?= "${@bb.utils.contains('PACKAGE_EXTRA_ARCHS', 'container-dummy-provides', 'container-dummy-provides', 'busybox', d)}" | ||
| 30 | |||
| 31 | # Allow build with or without a specific kernel | ||
| 32 | IMAGE_CONTAINER_NO_DUMMY = "1" | ||
| 33 | |||
| 34 | # Workaround /var/volatile for now | ||
| 35 | ROOTFS_POSTPROCESS_COMMAND += "rootfs_fixup_var_volatile ; " | ||
| 36 | rootfs_fixup_var_volatile () { | ||
| 37 | install -m 1777 -d ${IMAGE_ROOTFS}/${localstatedir}/volatile/tmp | ||
| 38 | install -m 755 -d ${IMAGE_ROOTFS}/${localstatedir}/volatile/log | ||
| 39 | } | ||
| 40 | |||
| 41 | OCI_IMAGE_ENTRYPOINT = "curl" | ||
| 42 | OCI_IMAGE_TAG = "easy" | ||
| 43 | OCI_IMAGE_ENTRYPOINT_ARGS = "http://localhost:80" | ||
| 44 | CONTAINER_SHELL = "busybox" | ||
| 45 | |||
| 46 | IMAGE_INSTALL:append = "curl" | ||
