Map Jira projects to GitLab repositories
Tell Label2Prod which GitLab repositories each Jira project uses, choose what can start a fix, and see how it picks the right repository.
Label2Prod needs to know where the code for each Jira project lives. You set that up once.
Import your Jira projects
In the Map projects to repositories step, press Import projects from your site. This brings in the site’s projects and sets up the notifications Label2Prod needs from Jira. Repeat it for each site you connected.
Map a project to its repositories
Pick a Jira project, pick a repository, and press Map. Repeat for every pair. A project can use several repositories, and one repository can serve several projects.
You can change the map at any time in Settings, under each project, with Add repository and Remove.
Choose what can start a fix
Each Jira project has its own settings:
- Switched on or off. Only switched-on projects start fixes.
- Trigger label. The label that starts a fix. It is
autofixunless you change it. - Issue types that can be fixed. Bug types are ticked when a project is imported. Tick Task or Story to let Label2Prod work on those too.
When someone labels an issue whose type is not ticked, Label2Prod says so in a comment on the issue and names the setting to change.
How Label2Prod picks the repository
When a project uses one repository, every fix goes there. When it uses several, Label2Prod looks for the one the issue names, in its text or its Components. When nothing says, it asks on the issue and lists the repositories to choose from; reply with a comment naming one and it carries on.
Tip: create one Jira component per repository, named after it, such as shop-web for acme/shop-web. Then whoever files the issue just picks the component.