Skip to content

Add job URL to container labels

Tomasz Maczukin requested to merge add-job-url-to-container-labels into master

What does this MR do?

Adds a job URL label to all containers created for a job by the Docker and Docker+Machine executors.

Why was this MR needed?

We currently label the containers with job's ID. However, this is not an unique identifier. One Runner with multiple [[runners]] configuration set to use Docker or Docker+Machine executor may handle jobs from different GitLab instances. Which means that at the same time two different container sets for two different jobs may get the same job ID label. While there is a really low probability of that to happen, using job URL will definitely make the information most precise. The job URL will contain information about GitLab's instance, project path and finally job ID.

What's the best way to test this MR?

What are the relevant issue numbers?

Edited by Tomasz Maczukin

Merge request reports

Loading