Commit Graph

11 Commits

Author SHA1 Message Date
Mikko Ylinen
e02c480ab7 images: use buildkit again
The Toybox images had two issues:

1. Distroless does not support /bin -> /usr/bin so we needed to
create it manually to get /bin/bash for Toybox. However, with this
Openshift image validation complains that we are touching the "base"
image.

2. We could not use buildkit since it fails with /bin symlink
copied over /bin directory from Distroless.

The simple fix is just to move away from all /bin/sh and /bin/bash
and use "/usr/bin/env bash" to resolve the path instead. This allows
to keep /bin untouched.

Signed-off-by: Mikko Ylinen <mikko.ylinen@intel.com>
2023-12-08 08:01:22 +02:00
Mikko Ylinen
900d0ebf9c images: have base image specific toybox config
Our *.Dockefile's allow builders to specify FINAL_BASE base image
to which static binaries are copied for the final image.

Initcontainers install toybox with a minimum set of "coreutils"
needed but with some final base images the minimum set can be
even smaller since they may already have /bin/sh, ls etc. installed.

Make initcontainers to have base image specific toybox-config.
For now, "static" for distroles/static and "ubi8-micro" for
UBI base image configs are created.

At the same time, move the toybox build to "usrmerge" based
setup where everything is installed to /usr/bin and /bin is
a symlink to /usr/bin. buildkit does not seem to like it so
disable buildkit usage for now.

Signed-off-by: Mikko Ylinen <mikko.ylinen@intel.com>
2023-09-08 09:38:18 +03:00
Mikko Ylinen
2b2892eb09 build: add BUILDER=podman
Signed-off-by: Mikko Ylinen <mikko.ylinen@intel.com>
2022-09-13 18:02:45 +03:00
chaitanya1731
4633f22b51 Images: Updated base image to use 'ubi8-micro' image from RedHat
Signed-off-by: chaitanya1731 <chaitanya.kulkarni@intel.com>
2022-02-23 13:56:40 -05:00
Mikko Ylinen
aee9dd20f8 images: force buildah to use runc
buildah 1.19.4 and its dependencies when installed from the
libcontainers OBS repo, defaulted to crun and that made the
image builds to fail.

By forcing buildah to use runc instead, everything works OK.

Signed-off-by: Mikko Ylinen <mikko.ylinen@intel.com>
2021-02-26 11:48:59 +02:00
Mikko Ylinen
a013595226 build: pass extra builder arguments from users
Users had no options to specify extra builder arguments to $BUILDER.

With this patch it's possible, e.g., to build QAT plugin with kernel
mode support:

make intel-qat-plugin EXTRA_BUILD_ARGS="--build-arg TAGS_KERNELDRV=kernel

Fixes: #234

Signed-off-by: Mikko Ylinen <mikko.ylinen@intel.com>
2020-03-16 20:19:16 +02:00
Mikko Ylinen
e6524eaada images: drop SRCREV tag
The SRCREV tag becomes a RepoTag we end up having those tags in the
registry too.

To keep the registry clean, drop SRCREV tags.

Signed-off-by: Mikko Ylinen <mikko.ylinen@intel.com>
2019-11-01 14:43:48 +02:00
Mikko Ylinen
d3354d0522 travis: Use vendored code for container builds
Signed-off-by: Mikko Ylinen <mikko.ylinen@intel.com>
2019-11-01 14:32:26 +02:00
Mikko Ylinen
d06f98690f images: tag with intel prefix
In preparations to get some of the images to hub.docker.com/intel,
start using intel/ prefix.

Moreover, set the Makefile variables so that the images built
by make [images|demos] can easily be pushed to any registry/org
by 'docker push' (e.g., by Jenkins).

Signed-off-by: Mikko Ylinen <mikko.ylinen@intel.com>
2019-08-29 13:21:19 +03:00
Mikko Ylinen
23598e7839 build-image: always pull the latest base image
With this change, we make sure the local build always pulls the
latest version of the base image.

Signed-off-by: Mikko Ylinen <mikko.ylinen@intel.com>
2019-05-14 20:39:36 +03:00
Ed Bartosh
891d69de83 Use buildah to build images
Added alternative builder for project images: buildah
https://github.com/containers/buildah

Considering that some of our plugins use CRI-O runtime it could be
a good idea to get rid of docker as a builder. It should allow us
not to run docker daemon at all, even for build purposes.

Kubernetes also goes this way encouraging users to switch to CRI
runtimes (CRI-O and containerd), so having non-docker builds supported
looks good from this perspective too.
2018-09-28 17:21:12 +03:00