Skip to main content

Installing QA-Board's client

You need to install QA-Board's CLI client: qa. It wraps and runs your code.

pip install qaboard

With your organization's site package​

Your organization may publish a site package that configures qa for its server. Install it too, e.g.:

pip install --upgrade 'qaboard-site-mysite @ git+ssh://git@git.example.com/infra/qaboard#subdirectory=deployments/mysite/cli'

The site packages auto-configure defaults such as the API URL, port, and other site-specific settings. You do not need to manually set environment variables for standard deployments. They can also provide default qaboard.yaml settings for all projects, like where results are stored or the LSF queue.

tip

Environment variables (e.g. QABOARD_HOST, QABOARD_PROTOCOL) always override site package defaults. This lets you point at a different server during development or testing without changing the installed package.

To make sure the installation was successful, try printing a list of qa's CLI commands:

qa --help

# If you get errors about not using a utf8 locale, you can likely:
# export LC_ALL=C.utf8 LANG=C.utf8

Connecting to a custom QA-Board server​

If you installed qaboard without a site package (or want to override the defaults), set these environment variables:

export QABOARD_HOST=my-server:5151
export QABOARD_PROTOCOL=http
# or, equivalently:
export QABOARD_URL=http://my-server:5151

Without any of them, qa uses http://localhost:5151 and prints a warning.

API token​

Some actions need a logged-in user (e.g. starting tuning or "redo" runs from scripts). Create an API token with a POST to /api/v1/user/token/ while logged-in (there is no UI for it yet, e.g. use your browser's dev tools on the web application), and save it as QA_TOKEN in the environment, or in a per-user secrets file readable only by you:

~/.qaboard/secrets.yaml (chmod 600, or set QA_USER_SECRETS to another path)
QA_TOKEN: <your token>

If your server uses HTTPS with a certificate your machines don't trust (e.g. from an internal CA), point QABOARD_API_VERIFY to the CA bundle, or disable the checks for requests to the API:

export QABOARD_API_VERIFY=/etc/ssl/certs/internal-ca.pem
export QABOARD_API_VERIFY=false