Reviewed-by: Sabelnikov, Dmitriy <dmitriy.sabelnikov@t-systems.com> Co-authored-by: weihongmin1 <weihongmin1@huawei.com> Co-committed-by: weihongmin1 <weihongmin1@huawei.com>
6.2 KiB
Updating a Configuration File
Function
You can update items in the .obsutilconfig file, including the endpoint, AK, SK, and token.
Configuration Parameters describes parameters in the .obsutilconfig file.
Command Line Structure
- Windows
obsutil config -interactive [-crr] [-config=xxx]
- macOS or Linux
./obsutil config -interactive [-crr] [-config=xxx]
Examples
- In Windows, run obsutil config -interactive to update the access keys and OBS endpoint in the default configuration file.
obsutil config -interactive Please input your ak: xxxxxxxxxxxxxxxxxxxxxxxxx Please input your sk: xxxxxxxxxxxxxxxxxxxxxxxxx Please input your endpoint: xxxxxxxxxxxxxxxxxxxxxxxxx Please input your token: xxxxxxxxxxxxxxxxxxxxxxxxx Config file url: C:\Users\tools\.obsutilconfig Update config file successfully!
- In Linux, run ./obsutil config -interactive to update the access keys and OBS endpoint in the default configuration file.
./obsutil config -interactive Please input your ak: xxxxxxxxxxxxxxxxxxxxxxxxx Please input your sk: xxxxxxxxxxxxxxxxxxxxxxxxx Please input your endpoint: xxxxxxxxxxxxxxxxxxxxxxxxx Please input your token: xxxxxxxxxxxxxxxxxxxxxxxxx Config file url: /root/.obsutilconfig Update config file successfully!
Parameter Description
Parameter |
Optional or Mandatory |
Description |
|---|---|---|
interactive |
Optional (additional parameter) |
Updates settings in interactive mode. |
crr |
Optional (additional parameter) |
Updates the settings of client-side cross-region replication. NOTE:
If this parameter is not specified, endpoint, ak, sk, and token will be updated. If this parameter is specified, endpointCrr, akCrr, skCrr, and tokenCrr will be updated. |
config |
Optional (additional parameter) |
The user-defined configuration file for executing the current command. For details about parameters that can be configured, see Configuration Parameters. By specifying this parameter and a path, you can update parameters in the user-defined configuration file. Otherwise, parameters in the default configuration file will be updated. |