Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GitLab MRs should be "Mergeable" if jobs are skipped or (only) Atlantis job failed #2252

Closed

Conversation

carlbordum
Copy link

Based off #2137 and @Skeen 's work. Also makes MR's mergable if commit statuses are skipped. This makes Atlantis much more suitable with monorepos, where you sometimes only run some tests (ie skip other jobs) based on the changes.

@carlbordum carlbordum requested a review from a team as a code owner May 10, 2022 09:46
@carlbordum carlbordum changed the title Fix pull is mergable GitLab MRs should be "Mergeable" if jobs are skipped or (only) Atlantis job failed May 10, 2022
@michelmzs
Copy link
Contributor

Hi @carlbordum, could you explain a situation where a skipped job blocks the Atlantis workflow?

@carlbordum
Copy link
Author

Take this example from the Gitlab CI documentation where they only want to run docker build when the Dockerfile changes (ofc this is strange, but fine for the example).

In this case, currently atlantis will not be able to apply because the CI job is not successful (its just skipped) and therefore we always have to run every job. This wastes a lot of time for developers as we are using a monorepo.

Hope it makes sense

@jamengual
Copy link
Contributor

@carlbordum Please add tests, thanks.

@michelmzs
Copy link
Contributor

Take this example from the Gitlab CI documentation where they only want to run docker build when the Dockerfile changes (ofc this is strange, but fine for the example).

In this case, currently atlantis will not be able to apply because the CI job is not successful (its just skipped) and therefore we always have to run every job. This wastes a lot of time for developers as we are using a monorepo.

Hope it makes sense

Are you sure that the current implementation will look for other status besides the external stage created by the Atlantis itself? I'm guessing that it won't block the workflow, I need to test.

@jamengual jamengual added feature New functionality/enhancement waiting-on-response Waiting for a response from the user labels May 13, 2022
@carlbordum
Copy link
Author

@jamengual sorry I will not use more time on this, feel free to close.

Yes @michelmzs, all ci jobs need to pass, maybe its the way we set Atlantis up.

@jamengual jamengual closed this Jun 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New functionality/enhancement waiting-on-response Waiting for a response from the user
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants