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

Improve Docker Compose handling #28

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

bartmkraus
Copy link
Member

Closes #26

Here's how this solution works:

  1. The docker-compose.base.yml contains all shared configuration
  2. Backend repo should has its own docker-compose.yml that extends from base and overrides necessary values
  3. zeton_full_stack repo has its docker-compose.yml that includes everything including the React client

I think that benefits of this are:

  • Single source of truth in docker-compose.base.yml
  • Backend repo can work independently
  • Easy to maintain as most configuration lives in one place
  • Flexibility to override settings when needed
  • Preserved all existing functionality including healthchecks

In the near future it would be nice add a docker-compose.override.yml in each repository for environment-specific settings for example: to make local development easier. I think @arkjedrz expressed his concerns about the distinction between production and development environments.

Copy link
Contributor

Choose a reason for hiding this comment

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

Why is it required to have both docker-compose.base.yml and docker-compose.yml?
It seems docker-compose,yml restates the content.

Copy link
Member Author

Choose a reason for hiding this comment

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

I've looked a bit into the future with the development and production environments in mind. Maintaining this structure makes it easier to add environment-specific configurations later without having to restructure that configuration. (Core configuration, Development overrides, Production overrides).

Copy link
Member Author

Choose a reason for hiding this comment

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

Related to this issue: zeton_django Issue #119

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.

Improve Docker Compose handling
2 participants