mirror of
https://ops.gitlab.net/gitlab-org/gitlab-build-images.git
synced 2025-12-11 02:52:56 +01:00
Finally bootstrapping?
This commit is contained in:
parent
eb588d0fae
commit
9337cd93fa
2 changed files with 41 additions and 2 deletions
|
|
@ -30,7 +30,7 @@
|
|||
- gitlab-org
|
||||
stage: kaniko
|
||||
resource_group: ${CI_COMMIT_REF_SLUG}_${CI_JOB_NAME}
|
||||
image: registry.gitlab.com/gitlab-org/frontend/frontend-build-images/build-image
|
||||
image: registry.gitlab.com/gitlab-org/gitlab-build-images/unstable/kaniko:1.0.0-eb588d0f
|
||||
script:
|
||||
- pwd
|
||||
- ls
|
||||
|
|
|
|||
|
|
@ -1,3 +1,42 @@
|
|||
# registry.gitlab.com/gitlab-org/gitlab-build-images/kaniko
|
||||
|
||||
This is a image around the `kaniko` executor
|
||||
This is an image that wraps and extends `kaniko`. It contains the following tools:
|
||||
|
||||
- [kaniko]: A tool to build images in Docker / Kubernetes
|
||||
- [crane]: A tool for managing container images (without the need to download them from registries)
|
||||
- [jq]: a lightweight and flexible command-line JSON processor
|
||||
|
||||
With this image you can build images without the need for Docker-in-Docker.
|
||||
The image is based on `alpine:git`, so you can utilize `apk` and `git` as well.
|
||||
|
||||
If you use this image in GitLab CI, it automatically logs in with credentials provided in GitLab CI.
|
||||
|
||||
[kaniko]: https://github.com/GoogleContainerTools/kaniko#readme
|
||||
[crane]: https://github.com/google/go-containerregistry/blob/main/cmd/crane/doc/crane.md
|
||||
[jq]: https://stedolan.github.io/jq/
|
||||
|
||||
## Usage
|
||||
|
||||
GitLab Docs on usage of [kaniko](https://docs.gitlab.com/ee/ci/docker/using_kaniko.html).
|
||||
|
||||
This image simplifies building with kaniko even further. `/kaniko/executor` and `/kaniko/warmer` are also
|
||||
aliased to `kaniko-executor` and `kaniko-warmer`.
|
||||
|
||||
```yaml
|
||||
build:
|
||||
stage: build
|
||||
image: registry.gitlab.com/gitlab-org/gitlab-build-images/kaniko
|
||||
script:
|
||||
- >-
|
||||
kaniko-executor
|
||||
--context "${CI_PROJECT_DIR}"
|
||||
--dockerfile "${CI_PROJECT_DIR}/Dockerfile"
|
||||
--destination "${CI_REGISTRY_IMAGE}:${CI_COMMIT_TAG}"
|
||||
rules:
|
||||
- if: $CI_COMMIT_TAG
|
||||
```
|
||||
|
||||
## Environment variables
|
||||
|
||||
- `BUILD_IMAGE_NO_MESSAGE`: per default prints a message with version information, set this variable to suppress it
|
||||
- `BUILD_IMAGE_NO_AUTO_LOGIN`: per default authenticating against the registry, set this variable to suppress this
|
||||
Loading…
Add table
Add a link
Reference in a new issue