gitlab-ci-local: Source files missing from service container
Is your feature request related to a problem? Please describe.
According to the docs, GitLab runners mount the $CI_PROJECT_DIR (/builds/group-name/project-name/) to both job containers and service containers. This allows docker-in-docker jobs like browser_performance to share files between the job container and the dind service container. It seems that gitlab-ci-local does not mount the build directory to service containers, which leads to the issue described in this older gitlab issue.
Describe the solution you’d like
Mount the same build volume that is generated for each job (gcl-job_name-xxxxxx-build) in all service containers
Describe alternatives you’ve considered
Might be able to use the --volume argument to mount something in .gitlab-ci-local/builds to be shared by both job and service containers?
Additional context Example of the browser_performance job failing:
---
include:
- template: Verify/Browser-Performance.gitlab-ci.yml
browser_performance:
variables:
URL: https://example.com
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Comments: 29 (19 by maintainers)
Just to double check, I created a test repo to verify.
Here is the job with gitlab-ci-local:
And here is the gitlab pipeline: https://gitlab.com/hseitz/dind-service-example/-/jobs/3164209642
I don’t have private DIND Gitlab runners, so I haven’t confirmed myself that the build directory is shared. But at the bottom of this section is reads: