Pr@main refactor healthcheck#1117
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR introduces support for configuring an application “context path” via the installer configs and updates the Docker image healthcheck to probe the service under that context path.
Changes:
- Add
SQLBOT_CONTEXT_PATHto the installer’sinstall.confand propagate it into the generatedsqlbot.confasCONTEXT_PATH. - Update Docker
HEALTHCHECKto use Pythonurlliband includeCONTEXT_PATHin the probe URL.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| installer/sqlbot/templates/sqlbot.conf | Exposes CONTEXT_PATH in the container env via installer templating. |
| installer/install.conf | Adds a new installer-facing configuration variable SQLBOT_CONTEXT_PATH. |
| Dockerfile | Modifies container healthcheck to probe a URL that incorporates the configured context path. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| # Add health check | ||
| HEALTHCHECK --interval=30s --timeout=10s --start-period=5s --retries=3 \ | ||
| CMD curl -f http://localhost:8000 || exit 1 | ||
| CMD python3 -c "import os, urllib.request; urllib.request.urlopen(f'http://localhost:8000/{os.environ.get(\"CONTEXT_PATH\", \"\")}', timeout=3)" || exit 1 |
| SQLBOT_SERVER_IMAGE_HOST=http://YOUR_SERVER_IP:MCP_PORT/images/ | ||
| ##Token过期时间: 60 minutes * 24 hours * 8 days = 11520 minutes | ||
| SQLBOT_ACCESS_TOKEN_EXPIRE_MINUTES=11520 | ||
| ## 上下文路径 |
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.
No description provided.