Lists all CNAME records mapped to a bucket.
Usage notes
Alibaba Cloud accounts can run this command without additional configuration. To run it as a RAM user or with Security Token Service (STS) credentials, the caller must have the oss:ListCname permission. For details, see Attach a custom policy to a RAM user.
Syntax
ossutil api list-cname --bucket <value> [flags]| Parameter | Type | Required | Description |
|---|---|---|---|
--bucket | string | Yes | The name of the bucket. |
Note
This command maps to the ListCname API operation. For supported global flags, see Global command-line options.
Examples
All examples query CNAME records for a bucket named examplebucket. By default, the output uses the native ossutil format. Use --output-format to get JSON or YAML instead.
List CNAME records in the default format:
ossutil api list-cname --bucket examplebucketList CNAME records in JSON format:
ossutil api list-cname --bucket examplebucket --output-format jsonList CNAME records in YAML format:
ossutil api list-cname --bucket examplebucket --output-format yaml