Configure BCE-CLI
Last Updated:2020-10-22
The configuration supports the CLI environment displayed in Chinese
To configure the CLI environment that supports Chinese display, execute the following commands for configuration:
$ export LANG=en_US.UTF-8
Note: Execute the command
$ locale
to view the language support of the current environment, if notLANG=en_US.UTF-8
, execute the above-mentioned command for modification.
(Optional) Configuration of AK/SK information
Before the BCE CLI tool is used, it is recommended to set Access Key and Secure Key. You can set AK and SK information by -c/--configure.
$ bce -c [<conf-path>]
$ BOS Access Key ID [None]: Enter Your AK
$ BOS Secret Access Key [None]: Enter Your SK
$ Default region name [bj]: Enter Your region
$ Default domain [bj.bcebos.com]: Enter Your host
Parameter | Description | Is it necessary to fill in |
---|---|---|
<conf-path> |
Automatically write the configuration file to a specified directory. When a user has multiple Baidu AI Cloud accounts, the configuration files of different accounts are written to different directories by specifying the <conf-path> . When the <conf-path> is not specified, the CLI automatically writes the configuration file to the current user home directory ~/.bce after configuration. |
No |
AK/SK | Baidu AI Cloud allocates a pair of AK/SK to each user, and the user can log in to the management console to get it. Refer to GetAKSK. | Yes |
region | bj (North China - Beijing); gz (South China - Guangzhou); su (East China - Suzhou) | No |
host | VPC service domain name, bcc.bj.baidubce.com (North China - Beijing); bcc.gz.baidubce.com (South China - Guangzhou); bcc.su.baidubce.com (East China - Suzhou). |
Yes |