Help us learn about your current experience with the documentation. Take the survey.
使用 Geo 站点
- 版本:Premium, Ultimate
- 产品:GitLab Self-Managed
在您设置数据库复制并配置 Geo 节点后,您可以像使用主站点一样使用离您最近的 GitLab 站点。
Git 操作
您可以直接推送到次要站点(支持 HTTP、SSH,包括 Git LFS),请求将被代理到主站点。
推送到次要站点时您看到的输出示例:
$ git push
remote:
remote: This request to a Geo secondary node will be forwarded to the
remote: Geo primary node:
remote:
remote: ssh://git@primary.geo/user/repo.git
remote:
Everything up-to-dateWeb 用户界面
次要站点上的 Web 用户界面是可读写的。作为用户,所有在主站点上允许的操作都可以在次要站点上无限制地执行。
次要站点上的 Web 界面访问请求会自动且透明地代理到主站点。
从 Geo 次要站点获取 Go 模块
Go 模块可以从次要站点拉取,但有一些限制:
- 需要配置 Git(使用
insteadOf)才能从 Geo 次要站点获取数据。 - 对于私有项目,需要在
~/.netrc中指定身份验证详细信息。
更多信息,请参阅 将项目用作 Go 包。