Geo: Make adding a Secondary node easier
Problem
Adding a secondary GeoNode
record is a manual, error-prone process. In particular, the name
field must match exactly.
The following discussion from !745 (merged) should be addressed:
-
@ashmckenzie started a discussion:
There isn't a convenient rake task to add the secondary node because the command must be run on the secondary, but written on the primary.
Proposal
First iteration
- Add
rake gitlab:geo:announce_secondary
to be run on a new secondary that securely announces it to the primary node.
Then choose one:
- Most convenient and least work option: The primary automatically adds a
GeoNode
record for the secondary (if this can done safely). - Otherwise: Click "Add this secondary" in the primary Geo Nodes UI.
Second iteration
- A new secondary basically runs
rake gitlab:geo:announce_secondary
every minute if a primaryGeoNode
exists and the machine doesn't match anyGeoNode
.
Edited by Michael Kozono