You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request. Searching for pre-existing feature requests helps us consolidate datapoints for identical requirements into a single place, thank you!
Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request.
If you are interested in working on this issue or have submitted a pull request, please leave a comment.
I would like to be able to have a different behaviour of matching repo keys mentioned in https://www.runatlantis.io/docs/server-side-repo-config.html#repo, most importantly to be able to define the same repo id multiple times, but with a different branch regex each time. This way I can define something like this:
- id: github.com/org/repo1
branch: /^prod$/
workflow: prod
allowed_workflows: [prod]
autodiscover:
mode: auto
- id: github.com/org/repo1
branch: /^qa$/
workflow: qa
allowed_workflows: [qa]
autodiscover:
mode: auto
- id: github.com/org/repo1
branch: /^dev$/
workflow: dev
allowed_workflows: [dev]
autodiscover:
mode: auto
which would match the repo selector that contains the most matches. Thus if repo1 is matched, it will only match the dev branch, only if it is the last occurrence, as it is above, but if it was first or second in the list, it wouldn't match at all.
Describe the solution you'd like
For example, if repo is matches AND branch is matches, stop there, and do not pick a later repo occurrence as mentioned in the doc link above: "If multiple repos match, the last match will apply."
Describe the drawbacks of your solution
This is a completely different behaviour than the one currently in place. Maybe an extra flag which allows you to pick the current one or the one proposed here would be nice, or actually essential, to have.
Describe alternatives you've considered
Do this configuration in the repo level config, by defining multiple projects
The text was updated successfully, but these errors were encountered:
Community Note
Describe the user story
I would like to be able to have a different behaviour of matching repo keys mentioned in https://www.runatlantis.io/docs/server-side-repo-config.html#repo, most importantly to be able to define the same repo id multiple times, but with a different branch regex each time. This way I can define something like this:
which would match the repo selector that contains the most matches. Thus if repo1 is matched, it will only match the dev branch, only if it is the last occurrence, as it is above, but if it was first or second in the list, it wouldn't match at all.
Describe the solution you'd like
For example, if repo is matches AND branch is matches, stop there, and do not pick a later repo occurrence as mentioned in the doc link above: "If multiple repos match, the last match will apply."
Describe the drawbacks of your solution
This is a completely different behaviour than the one currently in place. Maybe an extra flag which allows you to pick the current one or the one proposed here would be nice, or actually essential, to have.
Describe alternatives you've considered
Do this configuration in the repo level config, by defining multiple projects
The text was updated successfully, but these errors were encountered: