Skip to content

feat: add COCOINDEX_CODE_DB_PATH_MAPPING for custom database locations#116

Merged
georgeh0 merged 3 commits intomainfrom
g/db-path-mapping
Mar 22, 2026
Merged

feat: add COCOINDEX_CODE_DB_PATH_MAPPING for custom database locations#116
georgeh0 merged 3 commits intomainfrom
g/db-path-mapping

Conversation

@georgeh0
Copy link
Member

@georgeh0 georgeh0 commented Mar 22, 2026

Summary

  • Add COCOINDEX_CODE_DB_PATH_MAPPING env var to remap database file locations by path prefix, enabling Docker deployments where databases live on the container's native filesystem
  • Update all database path resolution points (project, daemon, CLI reset, config, doctor) to use the new mapping
  • Add unit tests for parsing/resolution and an e2e test verifying init → index → search → reset with mapped paths

Ref: #66

Test plan

  • Unit tests in test_settings.py::TestResolveDbDir cover parsing, matching, edge cases
  • E2E test test_session_db_path_mapping verifies full workflow with mapped database directory
  • CI

🤖 Generated with Claude Code

georgeh0 and others added 3 commits March 21, 2026 23:41
Allow remapping database file locations via environment variable, enabling
Docker deployments where databases live on the container's native filesystem
while source code is mounted from the host.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@georgeh0 georgeh0 merged commit 33334bc into main Mar 22, 2026
5 checks passed
@georgeh0 georgeh0 deleted the g/db-path-mapping branch March 22, 2026 07:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant