config#
View or export the effective CLI configuration.
Subcommands#
yr config dump: Output the merged final configuration (TOML).yr config template: Output the built-invalues.tomlandconfig.toml.jinjatemplates.
Usage#
yr config dump [OPTIONS]
yr config template
Parameters#
yr config dump supports:
-s, --set KEY=VALUE: Override configuration from the command line; can be specified multiple times.VALUEmust be a valid TOML literal.
Description#
The configuration merge priority for config dump (high to low):
-s/--setcommand-line overridesUser configuration file specified via
-c/--configor at the default pathBuilt-in default templates
Customize Configuration Based on Built-in config.toml.jinja#
The final effective configuration for yr is rendered and merged from the following two built-in files:
api/python/yr/cli/values.tomlapi/python/yr/cli/config.toml.jinja
If you want to adjust the startup parameters of a component, it is recommended to use a custom config.toml to override the corresponding fields, rather than modifying the built-in template files.
Recommended steps:
Execute
yr config templateto view the built-in template structure.Create a new
config.toml, writing only the fields you want to override.First execute
yr -c /path/to/config.toml config dumpto verify the rendered result.Execute
yr -c /path/to/config.toml start --master(orstart) to start.
Example (override component startup parameters):
[mode.master]
frontend = true
dashboard = true
[values]
log_level = "DEBUG"
[values.function_proxy]
ip = "10.88.0.4"
port = "22772"
grpc_listen_port = "22773"
[function_proxy.args]
enable_metrics = false
litebus_thread_num = 25
runtime_recover_enable = true
[ds_worker.args]
heartbeat_interval_ms = 120000
node_dead_timeout_s = 120
Verification and startup:
yr -c /path/to/config.toml config dump
yr -c /path/to/config.toml start --master
If you only want to temporarily change a single parameter, you can also avoid editing the file and directly use -s/--set, for example:
yr start --master -s 'function_proxy.args.enable_metrics=true'
values.toml Field Descriptions#
Built-in default values file path: api/python/yr/cli/values.toml.
Note
Fields containing {{ ... }} template variables in values.toml will be automatically populated by the CLI at startup, requiring no manual configuration from the user. The CLI will automatically retrieve and calculate these values based on the runtime environment (such as IP, timestamp, CPU, memory, ports, etc.).
Port fields commonly written as {{ 32379|check_port() }} indicate that the given port is preferred; if it is occupied, an available port will be automatically selected.
To override automatically calculated values, specify them via the -s/--set parameter, for example: -s 'values.host_ip="10.0.0.1"'.
[values] Core Fields#
Tip
Default values with {{ ... }} in the table below indicate that the field will be automatically populated at runtime, requiring no manual configuration.
Field |
Default Value |
Description |
|---|---|---|
|
|
Node IP. |
|
|
Deployment directory for this startup (typically under |
|
|
|
|
|
Available CPU (millicores). |
|
|
Available memory (MB). |
|
|
Shared memory (MB). |
|
|
Unique node ID (defaults based on hostname + pid). |
|
|
Global log level. |
|
|
Current |
|
|
|
|
|
|
[values.meta_store]#
Field |
Default Value |
Description |
|---|---|---|
|
|
Whether to enable meta store. |
|
|
Meta store address. |
|
|
Meta store mode. |
[values.ds.curve]#
Field |
Default Value |
Description |
|---|---|---|
|
|
Whether to enable Curve/ZMQ security features. |
|
|
Curve key directory. |
|
|
Cache authentication method ( |
|
|
Whether to enable cache authentication. |
[values.etcd] and etcd Security Configuration#
Field |
Default Value |
Description |
|---|---|---|
|
|
Whether to enable multi-master (multi-etcd node) mode. |
|
|
etcd authentication type (e.g., |
|
|
etcd table prefix. |
[values.etcd.auth]#
Field |
Default Value |
Description |
|---|---|---|
|
|
etcd certificate directory. |
|
|
etcd CA filename. |
|
|
etcd server certificate filename. |
|
|
etcd server private key filename. |
|
|
etcd client certificate filename. |
|
|
etcd client private key filename. |
[[values.etcd.address]]#
Field |
Default Value |
Description |
|---|---|---|
|
|
etcd node IP. |
|
|
etcd peer port. |
|
|
etcd client port. |
Component Address and Port Fields#
Configuration Section |
Field |
Default Value |
Description |
|---|---|---|---|
|
|
|
ds_master address. |
|
|
|
ds_master port. |
|
|
|
ds_worker address. |
|
|
|
ds_worker port. |
|
|
|
function_master address. |
|
|
|
global scheduler port. |
|
|
|
function_proxy address. |
|
|
|
function_proxy HTTP port. |
|
|
|
function_proxy gRPC port. |
|
|
|
function_agent address. |
|
|
|
function_agent port. |
Examples#
yr config dump
yr config dump -s 'values.ds_master.port=12123' -s 'values.fs.log.level="DEBUG"'
yr config template