Skip to content

CLI Reference

This page provides documentation for our command line tools.

run

Run nameko services. Given a python path to a module containing one or more nameko services, will host and run them. By default this will try to find classes that look like services (anything with nameko entrypoints), but a specific service can be specified via nameko run module:ServiceClass.

positional arguments:

module[:service class]

    python path to one or more service classes to run

Usage:

run [OPTIONS] module[:service class]

Options:

  --broker BROKER            Deprecated option for setting up RabbitMQ broker
                             URI. Use --define or --config and set AMQP_URI
                             instead.
  --backdoor-port HOST_PORT  Specify a port number to host a backdoor, which
                             can be connected to for an interactive
                             interpreter within the running service process
                             using `nameko backdoor`.
  -c, --config CONFIG        The YAML configuration file
  -d, --define KEY=VALUE     Set config entry. Overrides value loaded from
                             config file. Can be used multiple times. Example:
                             --define AMQP_URI=pyamqp://guest:guest@localhost
  --help                     Show this message and exit.

shell

Usage:

shell [OPTIONS]

Options:

  --broker BROKER                 Deprecated option for setting up RabbitMQ
                                  broker URI. Use --define or --config and set
                                  AMQP_URI instead.
  --interface [bpython|ipython|plain]
  -c, --config CONFIG             The YAML configuration file
  -d, --define KEY=VALUE          Set config entry. Overrides value loaded
                                  from config file. Can be used multiple
                                  times. Example: --define
                                  AMQP_URI=pyamqp://guest:guest@localhost
  --help                          Show this message and exit.

show-config

Output as YAML string the configuration that would be passed to a service. Useful for viewing config files that load values from environement variables.

Usage:

show-config [OPTIONS]

Options:

  -c, --config CONFIG     The YAML configuration file
  -d, --define KEY=VALUE  Set config entry. Overrides value loaded from config
                          file. Can be used multiple times. Example: --define
                          AMQP_URI=pyamqp://guest:guest@localhost
  --help                  Show this message and exit.