Solr代理服务

一个用于通过代理访问Solr搜索服务的工具,适用于需要远程访问本地Solr实例的场景。

  • by nealrauhauser
  • Python
  • 本地部署
  • 更新于
在 GitHub 查看 nealrauhauser/Solr7-mcp

使用说明

Solr7 mcp

大多数MCP服务器至少需要8.1。Open Semantic Search已冻结,运行7.7.3,因此需要此软件。

这将适用于具有附近OSS系统的Mac。我认为你可以在不安装Anaconda的情况下使用fastmcp,这就是我的系统的配置方式。

"solr7": {
  "command": "/opt/anaconda3/bin/fastmcp",
  "args": [
    "run",
    "/Users/yourusername/work/gits/solr7-mcp/solr7-mcp.py"
  ],
  "env": {
    "SOLR_URL": "http://yourossproxy:8983/solr"
  }
}

您不能直接在OSS上访问Solr,它绑定到localhost,试图调整它只会打破神秘的依赖关系。使用代理主机通过隧道将端口8983连接到可见性中。

此服务适用于Debian发行版。

[Unit]
Description=Outbound SSH tunnel binding to all IPs on Proxmox
After=network-online.target
Wants=network-online.target

[Service]
Type=simple
User=root
ExecStart=/usr/bin/ssh \
    -o ServerAliveInterval=30 \
    -o ServerAliveCountMax=3 \
    -o ExitOnForwardFailure=yes \
    -o GatewayPorts=yes \
    -N \
    -L 0.0.0.0:8983:localhost:8983 \
    oss-system

Restart=always
RestartSec=15

[Install]
WantedBy=multi-user.target

您可能希望在您的ossproxy的根目录~/.ssh/config中包含此项

Host oss-system
    HostName oss-system
    User root
    IdentityFile ~/.ssh/id_ed25519
    ServerAliveInterval 30
    ServerAliveCountMax 3
    GatewayPorts yes