Creating and updating profiles

    or

    Creating a profile - 图2

    where [profile_name] is an optional name of the profile being created or updated.

    The first step of the interactive scenario is different in the init and profile create commands:

    Init

    Profile Create

    Outputs a list of existing profiles (if any) and prompts you to make a choice: Create a new or update the configuration of an existing profile:

    1. Please choose profile to configure:
    2. [1] Create a new profile
    3. [2] test
    4. [3] local

    Creating a profile - 图4

    If you enter the name of an existing profile at this point, the YDB CLI proceeds to updating its parameters as if an option with the name of this profile was selected at once.

    If no profile name is specified in the command line, it is requested:

    1. Please enter configuration profile name to create or re-configure:

    Next, you’ll be prompted to sequentially perform the following actions with each connection parameter that can be saved in the profile:

    • Don’t save
    • Use current value (this option is available when updating an existing profile)

    Creating a new mydb1 profile:

    1. Run the command:

      1. ydb config profile create mydb1

      Creating a profile - 图6

    2. Specify the or don’t save this parameter for the profile:

    3. Enter the DB name or don’t save this parameter for the profile:

      1. Pick desired action to configure database:
      2. [1] Set a new database value
      3. [2] Don't save database for profile "mydb1"
      4. Please enter your numeric choice:

    4. In the last step, you’ll be prompted to activate the created profile to be used by default. Choose ‘n’ (No) until you read the article about :