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

Feature - Sort components by docker compose "depends_on" #1298

Merged
merged 3 commits into from
May 11, 2024

Conversation

MorningLightMountain713
Copy link
Contributor

@MorningLightMountain713 MorningLightMountain713 commented May 8, 2024

What this pull does

  • When importing a docker compose file, it takes into account the depends_on of the services.
  • Sorts the components by depends_on. I.e. The containers that are "depended on" are first in the list, so they get installed first. I.e if web depends_on mysql, mysql will get installed first.
  • Can specify both long form and short form depends_on however, only the keys are used for long_form.
  • Uses a DAG to resolve dependencies.
  • Any cycles and the components are left in their original state. I.e. if you have a depends_on b and b depends_on a.
  • Adds tests for topologicalSort.

@MorningLightMountain713
Copy link
Contributor Author

All tests passing

Screenshot 2024-05-08 at 3 42 46 PM

Copy link
Member

@Cabecinha84 Cabecinha84 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ack, nice work!

@Cabecinha84 Cabecinha84 merged commit 314c7fe into development May 11, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants