No git clone for some jobs in review-apps pipelines
From Draft to Ready
-
!127090 (merged) is merged
What does this MR do and why?
Reboot of !108140 (merged), after it has been reverted in !111446 (merged).
We are doing a few things differently in this MR:
- We download all
_VERSION
files from the root folder of the project - We download the files in parallel using
curl --parallel
- Support for private projects
What does it look like?
- We don't do a
git clone
(review-build-cng-env
job,review-deploy
job) - We now pass all necessary ENV variables (see the
review-build-cng-env
from this MR, and another one outside of this MR) - We download all files in parallel
🚀
Try it out locally
export CI_API_V4_URL=https://gitlab.com/api/v4
export CI_PROJECT_ID=15097062 # Any private project will do
export CI_COMMIT_SHA=master
export FILES_TO_DOWNLOAD=(README.md)
source scripts/utils.sh
# Invalid access token on a private project
export PROJECT_TOKEN_FOR_CI_SCRIPTS_API_USAGE=invalid-access-token
rm -rf urls_outputs.txt && download_files ${FILES_TO_DOWNLOAD}
# curl should return an error (401 or 404)
# Valid access token on a private project
export PROJECT_TOKEN_FOR_CI_SCRIPTS_API_USAGE=valid-access-token
rm -rf urls_outputs.txt && download_files ${FILES_TO_DOWNLOAD}
cat README.md # The correct content should be in this file
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by David Dieulivol