Skip to main content

Agent Commands

When the Agent is deployed in standard mode, you can use tingyun-admin to generate configuration files, check configuration files, start the Agent, and more.

tingyun-admin is the main command for the Agent. It requires parameters to work. Entering this command directly in the command line will provide corresponding prompts.

Generate Configuration File

The configuration file uses the standard ini file format. For details, see the Python official documentation. The command to generate the configuration file is as follows:

tingyun-admin generate-config licenseKey filename.ini
  • licenseKey: Optional. If not provided when generating the configuration file, you need to manually modify the generated configuration file later.
  • filename.ini: The name of the configuration file. It is recommended to use an absolute path.

Check Configuration File

Used to check the parameters set in the configuration file, but does not check the validity of the license. The command format is as follows:

tingyun-admin check-config filename.ini
  • filename.ini: Optional. The configuration file used by the Agent. If not provided, the command will check the system environment variable TING_YUN_CONFIG_FILE or TINGYUN_CONFIG_PROPERTIES.

Start Agent Command

Use this command to perform one-click embedding for the application. The prerequisite is that a configuration file is required. There are two ways to provide the configuration file: set the configuration file environment variable directly before the Agent start command, or set the operating system environment variable.

Assume the configuration file for the Agent is stored at /tmp/tingyun.ini.

Method 1:

TINGYUN_CONFIG_FILE=/tmp/tingyun.ini tingyun-admin run-program <application start command> <application start parameters>

Method 2:

export TINGYUN_CONFIG_FILE=/tmp/tingyun.ini

tingyun-admin run-program <application start command> <application start parameters>