diff --git a/docs/executors/docker.md b/docs/executors/docker.md index 1b6670c7e19458d84c9f56464eff05b81ebfbb88..d6edd6e784fb5515ba8cb5adbb0a38432c885f7b 100644 --- a/docs/executors/docker.md +++ b/docs/executors/docker.md @@ -1153,6 +1153,10 @@ feature-flag `FF_USE_NATIVE_STEPS`, which is disabled by default. The Docker executor supports running the [CI/CD steps](https://docs.gitlab.com/ee/ci/steps/) natively by using the `gRPC` API provided by [`step-runner`](https://gitlab.com/gitlab-org/step-runner). +- [Updated](https://gitlab.com/gitlab-org/gitlab-runner/-/merge_requests/5322) in GitLab 17.9.0. GitLab Runner + injects the `step-runner` binary into the build container and adjusts the `$PATH` environment variable accordingly. + This enhancement makes it possible to use any image as the build image. + To enable this mode of execution, you must specify CI/CD jobs using the `run` keyword instead of the legacy `script` keyword. Additionally, you must enable the `FF_USE_NATIVE_STEPS` feature flag. You can enable this feature flag at either the job or pipeline level. @@ -1163,23 +1167,26 @@ step job: variables: FF_USE_NATIVE_STEPS: true image: - name: registry.gitlab.com/gitlab-org/step-runner:v0 + name: alpine:latest run: - name: step1 script: pwd - name: step2 script: env - name: step3 - script: ls -Rlah --ignore .git ../ + script: ls -Rlah ../ ``` ### Known Issues -- The build image must include a `step-runner` binary in `$PATH`. To achieve this, you can either: +- In GitLab 17.9 and later, the build image must have the `ca-certificates` package installed or the `step-runner` will fail to pull the steps + defined in the job. Debian-based Linux distribution for example do not install `ca-certificates` by default. + +- In GitLab versions before 17.9, the build image must include a `step-runner` binary in `$PATH`. To achieve this, you can either: - Create your own custom build image and include the `step-runner` binary in it. - Use the `registry.gitlab.com/gitlab-org/step-runner:v0` image if it includes the dependencies you need to run your - job. + job. - Running a step that runs a Docker container must adhere to the same configuration parameters and constraints as traditional `scripts`. For example, you must use [Docker-in-Docker](#use-docker-in-docker-with-privileged-mode).
Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.
Alternative Proxies: