lavacli can be used with or without a configuration file. Having a configuration file will help when using more than one lava instance.

Without a configuration file

When using lavacli without any configuration file, the uri should be passed as a command line argument:

lavacli --uri devices list

The authentication can also be passed in the uri:

lavacli --uri devices list

Keep in mind, that any user on the same machine will then see the username and token in the process list.

With a configuration file

lavacli configuration file is stored in ~/.config/lavacli.yaml. This is a YAML dictionary where each key is an identity.

  username: admin
  token: my_secret_token
    uri: tcp://

When using lavacli, the identity can be used with -i or –identity:

lavacli -i admin@validation devices list
lavacli -i staging events listen

By default, the default identity will be used. Hence both commands are identitical:

lavacli devices list
lavacli -i validation devices list

Available options

For each identity, you have to set:

  • uri: the uri of the RPC endpoint.

You can also set:

  • username: the api username

  • token: the api token

  • version: the api version to use when talking to this instance

  • timeout: the http timeout (defaults to 20 seconds)

  • proxy: the uri to the proxy

  • verify_ssl_cert: set it to false to ignore SSL certificates errors (defaults to true)

  • events: zmq event configuration

The events key is a dictionary where you can specify:

  • uri: the uri of the events stream. If not specified, lavacli will ask the server.

  • socks_proxy: uri to the socks proxy, if needed