diff --git a/cli/service-sync.adoc b/cli/service-sync.adoc deleted file mode 100644 index a74aa0d..0000000 --- a/cli/service-sync.adoc +++ /dev/null @@ -1,24 +0,0 @@ -// Type: reference -[id="service-sync"] -= Service synchronization - -By default, `skupper init` creates a site that synchronizes all services from other sites that also have synchronization enabled. - -To disable service synchronization: - -[source, bash, subs=attributes+] ----- -$ skupper init --service-sync false ----- - -To check whether synchronization is enabled, check the value for `service-sync` in the output from the following command: - -[source, bash, subs=attributes+] ----- -$ kubectl get cm skupper-site -o json ----- - -Notes: - -* When considering whether services are synchronized between two sites, `service-sync` must be enabled on both sites. -* If you use the command `skupper service delete` on a site, that command only works if the service was created on that site. diff --git a/kubernetes/deployment-concerns.adoc b/kubernetes/deployment-concerns.adoc index dec82c7..fb64915 100644 --- a/kubernetes/deployment-concerns.adoc +++ b/kubernetes/deployment-concerns.adoc @@ -5,6 +5,7 @@ This guide focusses on the following goals: * xref:increased-traffic[] * xref:high-availability[] +* xref:service-sync[] // Type:procedure [id="increased-traffic"] @@ -101,3 +102,6 @@ data: Setting the number of routers to more than two does not provide increased availability and can adversely affect performance. Note: Clients must reconnect when a router restarts or traffic is redirected to a backup router. + + +include::service-sync.adoc[leveloffset=+1] \ No newline at end of file diff --git a/kubernetes/service-sync.adoc b/kubernetes/service-sync.adoc new file mode 100644 index 0000000..0a9990d --- /dev/null +++ b/kubernetes/service-sync.adoc @@ -0,0 +1,58 @@ +// Type: reference +[id="service-sync"] += Service synchronization + +By default, creating a site enables that site to synchronize all services from other default sites. +This means that all services exposed on the service network are available in the current site. +For example, if you expose the backend service in the `east` site, that service is automatically created in the `west` site. + +However, if you want more granular control over which services are available, you can disable `service-sync`. +This might be required if: + +* You expose many services and not all are required on all sites. +* You are concerned that a specific service is not available on a specific site. + +To disable service synchronization: + +[source, bash, subs=attributes+] +---- +$ skupper init --service-sync false +---- + +or use the following YAML: + +[source, yaml, subs=attributes+] +---- +apiVersion: v1 +kind: ConfigMap +metadata: + name: skupper-site +data: + name: my-site + service-sync: false +---- + +To check whether synchronization is enabled, check the value for `service-sync` in the output from the following command: + +[source, bash, subs=attributes+] +---- +$ kubectl get cm skupper-site -o json +---- + +If you disable service-sync and you want to consume an exposed service on a specific site, you can create that service using the following command: + +[source, bash, subs=attributes+] +---- +skupper service create +---- + +where `` is the service name on the site where the service is exposed +and `` is the port used to expose that service. + + +Notes: + +* When considering whether services are synchronized between two sites, `service-sync` must be enabled on both sites. +* If you use the command `skupper service delete` on a site, that command only works if the service was created on that site. +* Podman sites do not support `service-sync`. +