
Registry是一个基于Web的平台,通过CSW-T协议捕获地理空间内容,并将信息索引到Elasticsearch引擎中以实现快速搜索。它支持多目录管理,提供OpenSearch API扩展CSW标准功能,并集成MapProxy以实现对各类资源的TMS/WMTS访问。
!架构图(图片宽度80%)
以下安装步骤基于Ubuntu 14.04操作系统。
shwget -qO - https://packages.elastic.co/GPG-KEY-elasticsearch | sudo apt-key add - echo "deb https://packages.elastic.co/elasticsearch/2.x/debian stable main" | sudo tee -a /etc/apt/sources.list.d/elasticsearch-2.x.list sudo apt-get update && sudo apt-get install elasticsearch sudo sed -i -e 's/#ES_HEAP_SIZE=2g/ES_HEAP_SIZE=1g/' /etc/default/elasticsearch sudo service elasticsearch start
shwget https://github.com/boundlessgeo/registry/archive/master.zip unzip master.zip cd registry-master/
或使用Git克隆:
shgit clone https://github.com/boundlessgeo/registry.git cd registry
shpip install -r requirements.txt pip install -e .
shpython registry.py pycsw -c setup_db
shpython registry.py pycsw -c optimize_db
验证环境并安装pytest等依赖:
shpython setup.py test
服务器将在8000端口监听:
shpython registry.py runserver
shcurl http://localhost:8000/catalog
shcurl -XPUT http://localhost:8000/catalog/<catalog_slug>/csw
通过CSW事务
shcurl -XPOST -d @payload.xml http://localhost:8000/catalog/<catalog_slug>/csw
注意:必须先创建目录才能添加记录。
通过命令行
shpython registry.py pycsw -c load_records -p /records/files/path/ -s <catalog_slug>
所有记录
shcurl http://localhost:8000/api/
特定目录
shcurl http://localhost:8000/catalog/<catalog_slug>/api/
shcurl -XGET http://localhost:8000/layer/<layer_uuid>.xml
shcurl -XGET http://localhost:8000/layer/<layer_uuid>.yml
shcurl -XGET http://localhost:8000/layer/<layer_uuid>.png
shpython registry.py pycsw -c reindex -s catalog_slug
通过服务器请求
shcurl -XDELETE http://localhost:8000/catalog/<catalog_slug>/csw
通过命令行
shpython registry.py pycsw -c delete_records -s catalog_slug
说明:
a.matchDocs值表示搜索API返回的图层数量。在Registry中可以读取所有目录和图层,但添加图层时必须指定目录slug。
为开发和测试搜索API,可使用独立的swagger-ui服务器:
shopen -a Google\ Chrome --args --disable-web-security --user-data-dir
shgit clone git@github.com:swagger-api/swagger-ui.git python -m SimpleHTTPServer 8001
http://localhost:8000/api/config
shpython registry.py pycsw -c list_layers > uuids.txt
shcat uuids.txt | python registry.py check_layers > checked_uuids.txt
shcat checked_uuids.txt | python registry.py reliability
shpython setup.py test
错误信息:
xml<ows:ExceptionText>Transaction (insert) failed: record parsing failed: 'Csw' object has no attribute 'repository'</ows:ExceptionText>
原因1:Elasticsearch未运行。启动Elasticsearch服务即可解决。
原因2:数据库未配置。在控制台运行python registry.py pycsw -c setup_db。
错误信息:
xml<ows:ExceptionText>Transaction (insert) failed: ERROR: UNIQUE constraint failed: records.identifier.</ows:ExceptionText>
原因:记录已被添加到数据库中。
shpip install MapProxy==1.9.0
shcurl http://localhost:8000/layer/<layer_uuid>.yml > layer.yml
shmapproxy-util serve-develop layer.yml
?f=json,并验证图层坐标是否采用WGS84投影。以下是 ninjalikeme/registry 相关的常用 Docker 镜像,适用于 不同场景 等不同场景:
您可以使用以下命令拉取该镜像。请将 <标签> 替换为具体的标签版本。如需查看所有可用标签版本,请访问 标签列表页面。



探索更多轩辕镜像的使用方法,找到最适合您系统的配置方式
通过 Docker 登录认证访问私有仓库
无需登录使用专属域名
Kubernetes 集群配置 Containerd
K3s 轻量级 Kubernetes 镜像加速
VS Code Dev Containers 配置
Podman 容器引擎配置
HPC 科学计算容器配置
ghcr、Quay、nvcr 等镜像仓库
Harbor Proxy Repository 对接专属域名
Portainer Registries 加速拉取
Nexus3 Docker Proxy 内网缓存
需要其他帮助?请查看我们的 常见问题Docker 镜像访问常见问题解答 或 提交工单
docker search 限制
站内搜不到镜像
离线 save/load
插件要用 plugin install
WSL 拉取慢
安全与 digest
新手拉取配置
镜像合规机制
manifest unknown
no matching manifest(架构)
invalid tar header(解压)
TLS 证书失败
DNS 超时
域名连通性排查
410 Gone 排查
402 与流量用尽
401 认证失败
429 限流
D-Bus 凭证提示
413 与超大单层
来自真实用户的反馈,见证轩辕镜像的优质服务