Replace gitlab.topology_service in favour of gitlab.cell.topology_service_client
What does this merge request do and why?
As per #2348 (moved), I am replacing gitlab.topology_service in favour of gitlab.cell.topology_service_client
How to set up and validate locally
-
Modify your
gdk.ymlas follows:cells: enabled: true instance_count: 1 instances: - config: gitlab: cell: topology_service_client: enabled: true address: "127.0.0.1:50051" ca_file: /tmp/cell-2-ca-cert.pem certificate_file: /tmp/cell-2-client-cert.pem private_key_file: /tmp/cell-2-client-key.pem gitlab: cell: topology_service_client: enabled: true address: "127.0.0.1:50051" ca_file: /tmp/cell-1-ca-cert.pem certificate_file: /tmp/cell-1-client-cert.pem private_key_file: /tmp/cell-1-client-key.pem gitlab_topology_service: enabled: true -
Run
gdk reconfigureYou should see a similar diff to the following appear:
gitlab/config/gitlab.yml -------------------------------------------------------------------------------- @@ -813,8 +813,8 @@ production: &base skip_sequence_alteration: true topology_service_client: - address: 127.0.0.1:9095 - ca_file: /gdk/gitlab-topology-service/tmp/certs/ca-cert.pem - private_key_file: /gdk/gitlab-topology-service/tmp/certs/client-key.pem - certificate_file: /gdk/gitlab-topology-service/tmp/certs/client-cert.pem + address: 127.0.0.1:50051 + ca_file: /tmp/cell-1-ca-cert.pem + private_key_file: /tmp/cell-1-client-key.pem + certificate_file: /tmp/cell-1-client-cert.pem -
Check out this branch in the cells' directory:
cd gitlab-cells/cell-2; git checkout tskorupa/refactor-gitlab-cells-configuration; cd ../.. -
Run
gdk cells upYou should see a similar diff to the following appear:
gitlab/config/gitlab.yml -------------------------------------------------------------------------------- @@ -807,4 +807,14 @@ production: &base # secret_file: /home/git/gitlab/.gitlab_workhorse_secret + cell: + enabled: true + id: 2 + database: + skip_sequence_alteration: false + topology_service_client: + address: 127.0.0.1:50051 + ca_file: /tmp/cell-2-ca-cert.pem + private_key_file: /tmp/cell-2-client-key.pem + certificate_file: /tmp/cell-2-client-cert.pem gitlab_kas: gitlab/config/session_store.yml -------------------------------------------------------------------------------- @@ -1,4 +1,4 @@ development: - unique_cookie_key_postfix: true + unique_cookie_key_postfix: false cookie_key: "_gitlab_session" session_cookie_token_prefix: "cell-2" ✅️ Cell 2 is ready. -
Remove any replacements from
gdk.yml:cells: enabled: true instance_count: 1 instances: - {} gitlab_topology_service: enabled: true -
Run
gdk reconfigureYou should see a similar diff to the following appear:
gitlab/config/gitlab.yml -------------------------------------------------------------------------------- @@ -813,8 +813,8 @@ production: &base skip_sequence_alteration: true topology_service_client: - address: 127.0.0.1:50051 - ca_file: /tmp/cell-2-ca-cert.pem - private_key_file: /tmp/cell-2-client-key.pem - certificate_file: /tmp/cell-2-client-cert.pem + address: 127.0.0.1:9095 + ca_file: /gdk/gitlab-topology-service/tmp/certs/ca-cert.pem + private_key_file: /gdk/gitlab-topology-service/tmp/certs/client-key.pem + certificate_file: /gdk/gitlab-topology-service/tmp/certs/client-cert.pem -
Run
gdk cells upYou should see a. similar diff to the following appear:
gitlab/config/gitlab.yml -------------------------------------------------------------------------------- @@ -813,8 +813,8 @@ production: &base skip_sequence_alteration: false topology_service_client: - address: 127.0.0.1:50051 - ca_file: /tmp/cell-2-ca-cert.pem - private_key_file: /tmp/cell-2-client-key.pem - certificate_file: /tmp/cell-2-client-cert.pem + address: 127.0.0.1:9095 + ca_file: /gdk/gitlab-topology-service/tmp/certs/ca-cert.pem + private_key_file: /gdk/gitlab-topology-service/tmp/certs/client-key.pem + certificate_file: /gdk/gitlab-topology-service/tmp/certs/client-cert.pem gitlab_kas: ✅️ Cell 2 is ready.
Impacted Categories
The following categories relate to this merge request:
-
gdk-reliability - e.g. When a GDK action fails to complete. -
gdk-usability - e.g. Improvements or suggestions around how the GDK functions. -
gdk-performance - e.g. When a GDK action is slow or times out.
Merge request checklist
-
This MR references an issue describing the change. -
This change is backward compatible. If not, please include steps to communicate to our users. -
Tests added for new functionality. If not, please raise an issue to follow-up. -
Documentation added/updated, if needed. -
Announcement added, if change is notable. -
gdk doctortest added, if needed.
Edited by Tomasz Skorupa