The Nessie CLI is an easy way to get started with Nessie. It supports multiple branch and tag management capabilities. This is installed as
pip install pynessie. Additional information about
pynessie and release notes can be found at the PyPI site.
# python 3 required pip install pynessie
All the REST API calls are exposed via the command line interface. To see a list of what is available run:
$ nessie --help
All docs of the CLI can be found here.
You can configure the Nessie CLI by creating a configuration file as described below:
- Other Unix:
APPDATAenvironment variable falls back to
- Via the environment variable
The default config file is as follows:
auth: # Type can be either basic or aws type: basic # Username and password required if using basic auth username: <username> password: <password> timeout: 10 # Nessie endpoint endpoint: http://localhost/api/v1 # whether to skip SSL cert verification verify: true
The command line interface can be configured with most of the above parameters via flags or by setting a config directory. The relevant configs can also be set via environment variables. These take precedence. The environment variable format is to append
NESSIE_ to a config parameter and nested configs are separated by a _. For example:
NESSIE_AUTH_TIMEOUT maps to
auth.timeout in the default configuration file above.
Working with JSON¶
The Nessie CLI can return data in json format and can be used effectively with
jq. For example:
$ nessie --json branch -l | jq .
The Nessie CLI is built on the great Python Click library. It requires Python 3.x.