Fix QueryService and MLService silent startup failures#56
Draft
Fix QueryService and MLService silent startup failures#56
Conversation
Co-authored-by: Sulstice <11812946+Sulstice@users.noreply.github.com>
Co-authored-by: Sulstice <11812946+Sulstice@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix QueryService and MLService startup issue
Fix QueryService and MLService silent startup failures
Dec 17, 2025
Collaborator
|
@Sulstice are you still working on it? It's marked as draft. |
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.
Users see docker-compose reporting "Running" but QueryService (8010) and MLService (8007) are unreachable because services fail silently inside the container due to misconfigured environment variables.
Changes
Pre-flight validation (
validate_env.sh).envexists and critical variables are setPOSTGRES_PASSWORD,DB_PASSWORD,JWT_POSTGRES_DATABASE_PASSWORDstart_services.shto block startup on invalid configService health verification
/app/healthcheck.shin container to verify supervisor + all services are actually running and listeningstart_services.shthat shows per-service status with commands to view logs on failureContainer startup
Dockerfile.unifiedstartup scriptDocumentation
.envsetup requirements with password consistency rulesExample
Before:
$ ./start_services.sh ✔ Container brainkb-unified Running # Services at localhost:8007, localhost:8010 don't respond - no indication whyAfter:
Or if config is valid:
$ ./start_services.sh Service Status: ✓ api_tokenmanager: RUNNING ✓ query_service: RUNNING ✗ ml_service: EXITED To view logs: docker exec brainkb-unified tail -n 50 /var/log/supervisor/ml_service.err.logOriginal prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.