Use shortened token to generate metadata filename

Way way back, Joe created https://gitlab.com/gitlab-org/gitlab-runner/-/issues/36288+. That was fixed in Use job response file data to generate task met... (!86 - merged), however, in that change we started using the full token instead of the short token to create the metadata filename.

Today/yesterday a change was made elsewhere that changed the CI_JOB_TOKEN format to JWT ([Feature flag] Rollout of `ci_job_token_jwt` (gitlab-org/gitlab#497392)). This increased the length of the CI_JOB_TOKEN to a point where the metadata filename created above exceeded the 255 char filename max length in linux. This entirely broke the fargate runner.

The fix here is to use short token to create metadata filename. This is done by copy/pasting code from runner that does exactly that.

Closes #86 (closed)

I'll make a new release after this MR is merged.

Edited by Axel von Bertoldi

Merge request reports

Loading