1.4 KiB
1.4 KiB
Task Log - Fix Docker Healthcheck and Port Conflicts
Actions
-
Docker Configuration:
- Updated
starter/docker-compose.ymlpostgres healthcheck to explicitly specify the database name (-d ${POSTGRES_DATABASE:-lightrag_multitenant}). This fixes theFATAL: database "lightrag" does not existerrors in the logs.
- Updated
-
Test Script:
- Updated
starter/test_multi_tenant.shto check for and kill any process holding port 9621 before starting containers. This resolves theBind for 0.0.0.0:9621 failederror.
- Updated
Decisions
- Aggressive Port Cleanup: Added
lsof ... | xargs kill -9to the test script. This is necessary for a reliable "reset and run" experience in a dev environment where zombie processes might linger. - Healthcheck Precision: The default
pg_isreadybehavior (using username as dbname) was incorrect for our setup wherePOSTGRES_USER=lightragbutPOSTGRES_DB=lightrag_multitenant. Explicitly setting the database fixes the false negative healthchecks.
Next Steps
-
Run the Test Script:
cd starter ./test_multi_tenant.sh -
Verify Fixes:
- Watch the logs (via
docker-compose logs -fif needed) to ensure no more "database does not exist" errors appear. - Confirm the API container starts successfully without port conflict errors.
- Proceed with WebUI verification at
http://localhost:3000.
- Watch the logs (via