File tree 1 file changed +2
-3
lines changed
1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ few important details:
39
39
In the following example, kaniko is used to build a Docker image and then push
40
40
it to [ GitLab Container Registry] ( ../../user/project/container_registry.md ) .
41
41
The job will run only when a tag is pushed. A ` config.json ` file is created under
42
- ` /root /.docker ` with the needed GitLab Container Registry credentials taken from the
42
+ ` /kaniko /.docker ` with the needed GitLab Container Registry credentials taken from the
43
43
[ environment variables] ( ../variables/README.md#predefined-variables-environment-variables )
44
44
GitLab CI/CD provides. In the last step, kaniko uses the ` Dockerfile ` under the
45
45
root directory of the project, builds the Docker image and pushes it to the
52
52
name : gcr.io/kaniko-project/executor:debug
53
53
entrypoint : [""]
54
54
script :
55
- - mkdir -p /root/.docker
56
- - echo "{\"auths\":{\"$CI_REGISTRY\":{\"username\":\"$CI_REGISTRY_USER\",\"password\":\"$CI_REGISTRY_PASSWORD\"}}}" > /root/.docker/config.json
55
+ - echo "{\"auths\":{\"$CI_REGISTRY\":{\"username\":\"$CI_REGISTRY_USER\",\"password\":\"$CI_REGISTRY_PASSWORD\"}}}" > /kaniko/.docker/config.json
57
56
- /kaniko/executor --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/Dockerfile --destination $CI_REGISTRY_IMAGE:$CI_COMMIT_TAG
58
57
only :
59
58
- tags
You can’t perform that action at this time.
0 commit comments