Skip to content

Conversation

@phoevos
Copy link
Member

@phoevos phoevos commented Jan 15, 2025

Remove hardcoded container names from all services in the docker-compose files to allow multiple instances of the same service to run in parallel without conflicts. This is important to allow both scaling individual services as well as running multiple instances of the CMS stack locally for testing purposes.

Set the top-level project name in the docker-compose files so that it can be used as the default prefix for container names. Use cms for all stacks apart from the load tests (i.e. cms-load) and the dev deployment (i.e. dev-cms). The project name can be overridden on deployment through the -p command line flag or by setting the COMPOSE_PROJECT_NAME environment variable.

Note: Information that was previously only conveyed through the container names (e.g. model names for mlflow-models) was moved to a dedicated label. Apart from that, the MLFLOW_BACKEND_STORE_URI environment variable that is used to configure the garbage collection cronjob in the MLflow server was edited to use the mlflow-db service name instead of the container name (matching what we were already doing in the MLflow server startup script)

Remove hardcoded container names from all services in the docker-compose
files to allow multiple instances of the same service to run in parallel
without conflicts. This is important to allow both scaling individual
services as well as running multiple instances of the CMS stack
locally for testing purposes.

Signed-off-by: Phoevos Kalemkeris <[email protected]>
@phoevos phoevos added the enhancement New feature or request label Jan 15, 2025
@phoevos phoevos requested a review from baixiac January 15, 2025 15:37
Copy link
Member

@baixiac baixiac left a comment

Choose a reason for hiding this comment

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

LGTM. Can this also ensure container names follow the old cms prefixing style rather than use the project folder name?

Set the top-level project name in the docker-compose files so that it
can be used as the default prefix for container names. Use 'cms' for all
stacks apart from the load tests (i.e. 'cms-load') and the dev
deployment (i.e. 'dev-cms'). The project name can be overridden on
deployment through the '-p' command line flag or by setting the
'COMPOSE_PROJECT_NAME' environment variable.

Signed-off-by: Phoevos Kalemkeris <[email protected]>
@phoevos
Copy link
Member Author

phoevos commented Jan 16, 2025

@baixiac I've set cms as the top-level project name in the compose files to be used as the default prefix, but this is probably something that should be specified on deployment with the project name flag or environment variable to differentiate between environments.

@phoevos phoevos merged commit a55be7b into master Jan 16, 2025
5 checks passed
@phoevos phoevos deleted the feature-phoevos-unset-container-names branch January 16, 2025 13:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants