Skip to content

Geo: Fix GeoNode name in geo:update_primary_node_url rake task

Michael Kozono requested to merge mk/fix-node-name-vs-url into master

What does this MR do?

If in the configuration of a Geo node, you do not set gitlab_rails["geo_node_name"] in gitlab.rb, then the node's name defaults to external_url.

Therefore when you change the external_url of a node while following https://docs.gitlab.com/ee/administration/geo/disaster_recovery/#step-4-optional-updating-the-primary-domain-dns-record, then your Geo node's name will change as well.

This rake task is used to update the database record for that Geo node to make it match the machine configuration:

gitlab-rake geo:update_primary_node_url

Currently, the rake task updates the url of the DB record, but it does not update the name.

This MR fixes the rake task so it also updates the name when needed.

Screenshots

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Edited by Michael Kozono

Merge request reports