[[_container_build]] = Build .Provided Templates: |=== |Name |Description | .container-build-jib-maven | Builds the container with the Jib plugin for maven | .container-build-jib-gradle | Builds the container with the Jib plugin for gradle | .container-build-kaniko | Builds the container with Kaniko |=== Allows the simple building of Container Images. We use Kaniko because it is faster than Docker builds and has less security problems. The generated image will be passed as a tar-artifact between stages. This allows us to make further manipulations and scan jobs on the container image. The template <<_container_publish>> allows you to publish the build image to a registry. .Variables |=== |Name |Description | Default Value |CONTEXT_LOCATION | Defines the context of the container build. In case of jib, this path should point to the location of your Gradle/Maven projects. | $CI_PROJECT_DIR | EXTRA_ARGS | Additional argument that will be passed to the used tool. | "" | Only with Kaniko |- |- | DOCKERFILE_LOCATION | Path to the Dockerfile | $CI_PROJECT_DIR/Dockerfile | REGISTRY_MIRROR | Define the container mirror that should be used | exxcellent Nexus |=== :template: container/container-build.gitlab-ci.yml include::../../../template-printer.adoc[]