Fix local Docker startup loop and supervisorctl bootstrap issues#1074
Fix local Docker startup loop and supervisorctl bootstrap issues#1074
Conversation
…t launch of the container Fix 'cannot find /bootstrap.sh' in docker build
📝 WalkthroughWalkthroughThis pull request enhances Docker containerization by adding Supervisor RPC configuration for process control, implementing CRLF line-ending normalization in the Dockerfile, narrowing the startup readiness check to specifically verify PostgreSQL status, introducing dynamic port display in the bootstrap message, and assigning an explicit container name "prompts_library". Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~22 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
📝 Coding Plan
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment Tip You can customize the high-level summary generated by CodeRabbit.Configure the |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@DOCKER.md`:
- Line 189: The docker run example uses the container name "prompts_library"
which is inconsistent with the rest of the doc that references "prompts"; update
the docker run command to use the same container name ("prompts") or
alternatively normalize all other commands to "prompts_library" so they match;
search for occurrences of the strings "prompts_library" and "prompts" and make
them consistent throughout (e.g., in the docker run line and the operational
commands that reference the container name).
In `@docker/bootstrap.sh`:
- Around line 168-176: The banner currently uses DISPLAY_PORT (computed from
HOST_PORT or PORT) but gives no hint when DISPLAY_PORT is actually a container
port (when HOST_PORT is unset); update the startup banner logic around the
DISPLAY_PORT/echo lines so that if HOST_PORT is unset you append a short
clarifying note like "(container port — map with -p host:container to access via
localhost)" or similar, otherwise show "(host port)"; reference the DISPLAY_PORT
variable and the HOST_PORT/PORT resolution so you modify the echo block that
prints "Open http://localhost:${DISPLAY_PORT}" to include this conditional hint.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: f05f3941-00f4-4b4b-ab7a-ee1933960c15
📒 Files selected for processing (4)
DOCKER.mddocker/Dockerfiledocker/bootstrap.shdocker/supervisord.conf
Description
This PR fixes local Docker startup issues encountered on first container launch.
Main updates:
supervisorctlreadiness check indocker/bootstrap.shto wait forpostgresqlrunning state (instead of a generic status check that could loop).docker/supervisord.confsosupervisorctlcan connect reliably.docker/Dockerfileby normalizing/bootstrap.shline endings before execution.docker/bootstrap.shto show a host-usable port (HOST_PORTfallback).Small Changes:
DOCKER.mdlocal run command to include a container name for easier local management.Type of Change
Additional Notes
This is focused on local/self-hosted container behavior, especially Windows-based development flows.
Key issue addressed: startup loop around "starting supervisord" and
/bootstrap.shexecution reliability.Summary by CodeRabbit
Documentation
New Features
Bug Fixes