-
Notifications
You must be signed in to change notification settings - Fork 110
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Custom build directories with GIT_CLONE_PATH #1207
Comments
On a similar note, For example on a real GitLab CI run, these are the builtin variables I get: CI_PROJECT_PATH: firmware/myproject
CI_BUILDS_DIR: /builds
CI_PROJECT_DIR: /builds/firmware/myproject # aka "${CI_BUILDS_DIR}/${CI_PROJECT_PATH}" , at least in my runner setup And "myproject" is a subcomponent of what we'll call the "super_project", so I need to do a directory shuffle in order to do a build, like so: variables:
SUPER_PROJECT_DIR: ${CI_PROJECT_DIR}/super_project # /builds/firmware/myproject/super_project
ACTUAL_PROJECT_DIR: ${SUPER_PROJECT_DIR}/myproject # /builds/firmware/myproject/super_project/myproject
ARTIFACTS_DIR: ${CI_PROJECT_DIR}/artifacts
script:
- |
cd ${CI_BUILDS_DIR}
mv ${CI_PROJECT_DIR} ${CI_BUILDS_DIR}/tempspace
mkdir -p ${CI_PROJECT_DIR}
git clone --depth=1 https://oauth2:${GL_TOKEN}@... ${SUPER_PROJECT_DIR}
mv ${CI_BUILDS_DIR}/tempspace ${ACTUAL_PROJECT_DIR}
cd ${ACTUAL_PROJECT_DIR}
./do_the_build destination=${ARTIFACTS_DIR} I can't currently do script step 2 with gitlab-ci-local. So even without |
|
|
Is your feature request related to a problem? Please describe.
Hi! Love this project, however it does not currently work with my GitLab projects where
GIT_CLONE_PATH
is set, as CI builds in those repos are where they're just a piece of a larger puzzle and I have to clone other items directly inCI_PROJECT_PATH
. Basically it just allows the GitLab project being CI'd to start off in a subdirectory.Describe the solution you'd like
Pretty much just what the GitLab docs state for it:
It just clones the GitLab project into the provided
GIT_CLONE_PATH
directory instead of the default.Describe alternatives you've considered
Other than manually moving items around, which I'm not too keen on doing.
Additional context
Not really, just letting you know this is a feature that's missing! Thanks! :)
The text was updated successfully, but these errors were encountered: