MCP (Model Context Protocol) server for OpenGrok code search. Designed for AOSP 15-scale codebases and corporate deployments.
MCP (Model Context Protocol) сервер для поиска по коду OpenGrok. Спроектирован для кодовых баз масштаба AOSP 15 и корпоративного деплоя.
| EN | RU | |
|---|---|---|
| Full-text search | Code, definitions, references, file paths, history | Полнотекстовый поиск, определения, ссылки, пути к файлам, история |
| File inspection | Content, definitions in file, annotation (blame), genre detection | Содержимое файлов, определения в файле, аннотация (blame), определение типа |
| Navigation | Directory listing, projects, groups, repository properties | Список директорий, проекты, группы, свойства репозиториев |
| Suggestions | Autocomplete for all search fields | Автодополнение для всех поисковых полей |
25 MCP tools — full OpenGrok REST API coverage. 25 MCP-инструментов — полное покрытие OpenGrok REST API.
docker pull rd2w/opengrok-mcp:latest
docker run -d -p 8080:8080 \
-v ./config:/config:ro \
--env-file ./config/.env \
rd2w/opengrok-mcp:latest
Config example — config/config.example.toml. Пример конфига — config/config.example.toml.
Two transport modes (can run both simultaneously): Два режима транспорта (можно запустить оба одновременно):
docker exec and local deployment / для docker exec и локального деплояBearer token or HTTP Basic Auth. Credentials are loaded from environment variables (never from the config file). Custom corporate CA certificates supported via OPENGROK_CA_CERT.
Bearer-токен или HTTP Basic Auth. Креды загружаются из переменных окружения (никогда из конфиг-файла). Поддержка самоподписных корпоративных сертификатов через OPENGROK_CA_CERT.
| Feature | Detail |
|---|---|
| Rate limiting | GCRA token bucket, configurable RPS and burst |
| Caching | In-memory LRU cache (Mutex<LruCache>), TTL + LRU eviction |
| HTML stripping | Automatic cleanup of OpenGrok HTML responses |
| Pagination | has_more hints for large result sets |
| TLS | rustls with custom CA certificate support |
| Health endpoints | /healthz (liveness), /readyz (readiness), /metrics (Prometheus) |
| DNS Rebind Protection | Host header validation via allowed_hosts |
| Air-gapped deployment | Self-contained ~23 MB image (UPX-compressed), docker save → docker load without internet |
| Multi-arch | linux/amd64, linux/arm64 |
services:
opengrok-mcp:
image: rd2w/opengrok-mcp:latest
ports:
- "8080:8080"
volumes:
- ./config:/config:ro
env_file:
- ./config/.env
restart: unless-stopped
Content type
Image
Digest
sha256:137a5793b…
Size
7.8 MB
Last updated
about 1 month ago
docker pull rd2w/opengrok-mcp