Unable to specify a custom build directory on windows runners using GIT_CLONE_PATH variable
Unable to specify a custom build directory on windows
Steps to reproduce
- Setup a build runner on windows running a shell builder and with custom build directories enabled
- Setup a project with the
GIT_CLONE_PATHvariable set to
- Run the build
What is the current bug behavior?
Build fails with:
ERROR: Job failed: the GIT_CLONE_PATH="E:\\GitLab-Cloud-Runner\\builds\\ne-gateway" has to be within "E:\\GitLab-Cloud-Runner/builds"
The value of
GIT_CLONE_PATH is correct, it is under the required folder and the build should proceed.
What is the expected correct behavior?
The build should proceed using the folder as specified.
This seems to be because the difference in path
E:\\GitLab-Cloud-Runner\\builds\\ne-gateway and we are doing a simple string prefix match which don't end up matching.
We need to update it so it doesn't so it handles the difference between