Configuration variables

Prev Next

You can set configuration variables for each gateway using an environment variable or a configuration file. The system reads configuration variables in the following priority order:

  1. Environment variable (for example, GATEWAY_APPLICATION_WORKING_DIR)
  2. A single configuration file. The system uses the following location precedent:
    1. Path passed using --config <path> from the CLI when you launch the gateway
    2. Path set using GATEWAY_CONFIG environment variable
    3. ~/.gateway.d/gateway.conf
    4. /etc/gateway/gateway.conf
  3. Default value

To view loaded configuration variables in a gateway, run:

iagctl version --show-config

Example configuration file

When you create a configuration file, reference this example as a starting point:

[application]
#mode                = local
#ca_certificate_file = 
#cluster_id          = cluster_1
#working_dir         = ~/.gateway.d

[client]
#certificate_file =
#host             =
#port             = 50051
#private_key_file =
#use_tls          = true

[connect]
#certificate_file     = /etc/gateway/gw-manager.pem
#private_key_file     = /etc/gateway/gw-manager-key.pem
#enabled              = true
#server_ha_enabled    = false
#server_ha_is_primary = false
#hosts                 = 

[features]
#ansible_enabled  = true
#hostkeys_enabled = true
#opentofu_enabled = true
#python_enabled   = true

[log]
#console_json       = false
#file_enabled       = true
#file_json          = false
#level              = INFO
#server_dir         = /var/log/gateway
#timestamp_timezone = utc

[runner]
#announcement_address =
#certificate_file     =
#listen_address       = 127.0.0.1
#port                 = 50051
#private_key_file     =
#runtime_data_dir     = /var/lib/gateway
#use_tls              = true

[secrets]
#encrypt_key_file =

[server]
#api_key_expiration = 1440
#certificate_file   =
#distributed_execution      = true
#listen_address     = 127.0.0.1
#port               = 50051
#private_key_file   =
#runtime_data_dir   = /var/lib/gateway
#use_tls            = true

[store]
#backend                      = local
#etcd_hosts                   = "localhost:2379" # space separated list
#etcd_use_tls                 = true
#etcd_ca_certificate_file     =
#etcd_certificate_file        =
#etcd_client_cert_auth        = false
#etcd_private_key_file        =

[terminal]
#no_color           = false
#timestamp_timezone = utc

Learn more

For more detailed information on the available configuration variables, see: