Get release by tag name with $CI_JOB_TOKEN returns "404 Project Not Found"
Summary
This was first discovered with release-cli get
where it fails but release-cli create
works fine.
I'm assuming this is because the project is private.
Steps to reproduce
- Create private project
- Create job with script like
curl -s -H "JOB-TOKEN: $CI_JOB_TOKEN" "https://gitlab.example.com/api/v4/projects/$id/releases/$tag"
- This will produce a "404 Project Not Found" error
What is the expected correct behavior?
Either a 200 response with the release or a "404 Not Found" response should be returned.