Improve support of Geo secondaries behind a load balancer
I'll open another issue for those items. It makes sense to address only the main blocker (secondary authentication) here. These items are incremental improvements on top of that.
A customer wants to run all Geo Nodes behind a location aware load balancer so their users don't need knowledge of Geo. This is not currently possible. Other than https://gitlab.com/gitlab-org/gitlab-ee/issues/6306, they also need the following items addressed. => Support putting the primary behind a Geo node load balancer
Use Alternate URL in Git clone HTTP host and SSH destination https://gitlab.com/gitlab-org/gitlab-ee/issues/9123#note_153104896The Edit button URL for Geo nodes should be relative, not absolute using the external URL.
Scope has been cut to include only secondaries behind a load balancer. No primary yet.
-
Don't hard-code gitlab-ctl replicate
DB name togitlabhq_...
. => omnibus-gitlab!3124 (merged) -
Remove Alternate URL => https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/10609 -
Decouple node identity from External URL, so External URL can be used with more flexibility. See https://gitlab.com/gitlab-org/gitlab-ee/issues/9123#note_156172347, copied below:
Perhaps a way to clean up Geo
Don't reuse
external_url
as a unique identifier for "which GeoNode am I?".E.g.:
- Add
gitlab_rails['geo_node_name']
togitlab.rb
and default it toexternal_url
.- Rename GeoNode#url to GeoNode#name. It will be expected to match
gitlab_rails['geo_node_name']
.- Whereever we use GeoNode#url as an identifier, use GeoNode#name
- Whereever we use GeoNode#url as a URL that something needs to actually contact, instead use
external_url
(orinternal_url
, which is being introduced in https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/9634).- Profit???
UK (primary) USA (secondary 1) China (secondary 2) gitlab.rb external_url https://gitlab.com https://secondary.gitlab.com https://secondary.gitlab.com gitlab.rb geo_node_name uk.gitlab.com us.gitlab.com cn.gitlab.com GeoNode name uk.gitlab.com us.gitlab.com cn.gitlab.com GeoNode internal_url https://uk.gitlab.com (or let it default to external_url)
- Customer ticket: https://gitlab.zendesk.com/agent/tickets/106018 (internal use)
- Slack discussion during customer call: https://gitlab.slack.com/archives/C32LCGC1H/p1540571721004700 (internal use)