feat(config): enable Docker Compose auto-start in HTTP mode only#70
Open
adityamparikh wants to merge 1 commit intoapache:mainfrom
Open
feat(config): enable Docker Compose auto-start in HTTP mode only#70adityamparikh wants to merge 1 commit intoapache:mainfrom
adityamparikh wants to merge 1 commit intoapache:mainfrom
Conversation
Spring Boot Docker Compose integration now starts automatically when running locally with the HTTP profile (PROFILES=http ./gradlew bootRun). In STDIO mode, Docker Compose is explicitly disabled because STDIO requires a clean stdout channel and container management is not useful for that transport. The Jib container image already disables Docker Compose via SPRING_DOCKER_COMPOSE_ENABLED=false; an expanded comment explains why. Also updates all documentation to prefer the PROFILES environment variable over the --spring.profiles.active flag for consistency with the runtime configuration approach used by Docker and the JAR launcher. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> Signed-off-by: adityamparikh <aditya.m.parikh@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
spring.docker.compose.enabled=truetoapplication-http.propertiesso runningPROFILES=http ./gradlew bootRunautomatically starts Solr, ZooKeeper, and other services declared incompose.yamlbefore the application context initialises.spring.docker.compose.enabled=falsetoapplication-stdio.propertiesto disable Docker Compose in STDIO mode, where it is not useful and would pollute stdout.build.gradle.kts(Jib container config) to explain whySPRING_DOCKER_COMPOSE_ENABLED=falseis baked into the container image (Docker Compose cannot start sibling containers without a Docker socket mount).dev-docs/DEVELOPMENT.md,dev-docs/TROUBLESHOOTING.md, anddocs/AUTH0_SETUP.mdto consistently use thePROFILESenvironment variable (PROFILES=http ./gradlew bootRun) instead of the--spring.profiles.activeargument flag.Test plan
PROFILES=http ./gradlew bootRunand verify Solr starts automatically via Docker Compose without any manualdocker compose upstep../gradlew bootRun(STDIO mode) and verify Docker Compose is not invoked (no container startup output)../gradlew buildpasses with no test regressions.🤖 Generated with Claude Code