From b79e1245c1bf765c97462f322c09965314317b0a Mon Sep 17 00:00:00 2001 From: David Yu Date: Thu, 6 Jul 2023 12:25:12 -0700 Subject: [PATCH] Update website/content/docs/k8s/annotations-and-labels.mdx Co-authored-by: Tu Nguyen --- website/content/docs/k8s/annotations-and-labels.mdx | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/website/content/docs/k8s/annotations-and-labels.mdx b/website/content/docs/k8s/annotations-and-labels.mdx index 83295c993caa..5df96f3a29e0 100644 --- a/website/content/docs/k8s/annotations-and-labels.mdx +++ b/website/content/docs/k8s/annotations-and-labels.mdx @@ -288,28 +288,34 @@ Resource labels could be used on a Kubernetes service to control connect-inject The following Kubernetes resource annotations could be used on a pod to [Service Sync](https://developer.hashicorp.com/consul/docs/k8s/service-sync) behavior: - `consul.hashicorp.com/service-sync`: If this is set to `true`, then the Kubernetes service is explicitly configured to be synced to Consul. + ```yaml annotations: 'consul.hashicorp.com/service-sync': 'true' ``` -- `consul.hashicorp.com/service-port`: Configures the port to register to the Consul Catalog for the Kubernetes service. The annotation value may be a name of a port (recommended) or an exact port value. See [service ports](https://developer.hashicorp.com/consul/docs/k8s/service-sync#service-ports) for more information. + +- `consul.hashicorp.com/service-port`: Configures the port to register to the Consul Catalog for the Kubernetes service. The annotation value may be a name of a port (recommended) or an exact port value. Refer to [service ports](https://developer.hashicorp.com/consul/docs/k8s/service-sync#service-ports) for more information. + ```yaml annotations: 'consul.hashicorp.com/service-port': 'http' ``` + - `consul.hashicorp.com/service-tags`: A comma separated list of strings (without whitespace) to use for registering tags to the service registered to Consul. These custom tags automatically include the `k8s` tag which can't be disabled. ```yaml annotations: 'consul.hashicorp.com/service-tags': 'primary,foo' ``` -- `consul.hashicorp.com/service-meta-KEY`: A map for specifying service metadata for Consul services. The "KEY" below can be set to any key. This allows setting multiple meta values. + +- `consul.hashicorp.com/service-meta-KEY`: A map for specifying service metadata for Consul services. The "KEY" below can be set to any key. This allows you to set multiple meta values. ```yaml annotations: 'consul.hashicorp.com/service-meta-KEY': 'value' ``` -- `consul.hashicorp.com/service-weight:` - Configure ability to support weighted loadbalancing by service annotation for Catalog Sync. The integer provided will be applied as a weight for the `passing` state for the health of the service. See [weights](/consul/docs/services/configuration/services-configuration-reference#weights) in service configuration for more information on how this is leveraged for services in the Consul catalog. + +- `consul.hashicorp.com/service-weight:` - Configures ability to support weighted loadbalancing by service annotation for Catalog Sync. The integer provided will be applied as a weight for the `passing` state for the health of the service. Refer to [weights](/consul/docs/services/configuration/services-configuration-reference#weights) in service configuration for more information on how this is leveraged for services in the Consul catalog. ```yaml annotations: