fe2f650240
* ACL * ACL * Catalog * consul config * consul connect * top-level updates * consul intention * consul kv * consul namespace * consul peering * consul peering delete * consul services * consul snapshot * consul tls * consul acl auth-method * acl binding-rule * acl policy * acl role * acl token * fix * standardization * Update website/content/commands/snapshot/save.mdx Co-authored-by: Bryce Kalow <bkalow@hashicorp.com> * consul debug consul keyring Co-authored-by: Bryce Kalow <bkalow@hashicorp.com> Co-authored-by: Tu Nguyen <im2nguyen@users.noreply.github.com>
50 lines
1.2 KiB
Plaintext
50 lines
1.2 KiB
Plaintext
---
|
|
layout: commands
|
|
page_title: 'Commands: Peering List'
|
|
description: |
|
|
The `consul peering lists` command outputs a list of the local cluster's cluster peering connections, including imported and exported service counts and the connection state.
|
|
---
|
|
|
|
# Consul Peering List
|
|
|
|
Command: `consul peering List`
|
|
|
|
Corresponding HTTP API Endpoint: [\[GET\] /v1/peerings](/consul/api-docs/peering#list-all-peerings)
|
|
|
|
The `peering list` lists all peering connections.
|
|
The results are filtered according to ACL policy configuration.
|
|
|
|
The table below shows this command's [required ACLs](/consul/api-docs/api-structure#authentication).
|
|
|
|
| ACL Required |
|
|
| ------------ |
|
|
| `peering:read` |
|
|
|
|
## Usage
|
|
|
|
Usage: `consul peering list [options]`
|
|
|
|
#### Command Options
|
|
|
|
- `-format={pretty|json}` - Command output format. The default value is `pretty`.
|
|
|
|
#### Enterprise Options
|
|
|
|
@include 'http_api_partition_options.mdx'
|
|
|
|
#### API Options
|
|
|
|
@include 'http_api_options_client.mdx'
|
|
|
|
## Examples
|
|
|
|
The following example lists all peering connections associated with the cluster:
|
|
|
|
```shell-session hideClipboard
|
|
$ consul peering list
|
|
Name State Imported Svcs Exported Svcs Meta
|
|
cluster-02 ACTIVE 0 2 env=production
|
|
cluster-03 PENDING 0 0
|
|
```
|
|
|