Configuring Adjutant

Adjutant is designed to be highly configurable for various needs. The goal of Adjutant is to provide a variety of common tasks and actions that can be easily extended or changed based upon the needs of your OpenStack cluster.

For configuration Adjutant uses a library called CONFspirator to define and register our config values. This makes the app better at processing defaults and checking the validity of the config.

An example Adjutant config file is found in conf/adjutant.yaml, and a new one can be generated by running:

tox -e venv -- adjutant-api exampleconfig --output-file /etc/adjutant/adjutant.yaml

With --output-file controlling where the file goes. If the file extension is given as toml rather than yaml, a toml format config file will be generated instead.

This example file should be your starting point for configuring the service, and your core source of documentation for what each config does.

Adjutant will read the file from /etc/adjutant/adjutant.yaml or /etc/adjutant/adjutant.toml, and if the environment variable ADJUTANT_CONFIG_FILE is set, will look for the file in the specified location.

Note

While Adjutant does support toml as a config format, you are likely better off sticking with yaml as it may prove easier and more reliable, but for those who much prefer an ini type format, that might feel closer.

Configuration options

Django group

The first part of the configuration file contains standard Django settings, and for the most part the generated example config will explain all the options.

Identity group

Are the configs for how Adjutant interacts with Keystone, with the important ones being as follows:

adjutant.identity.username_is_email impacts account creation, and email modification actions. In the case that it is true, any task passing a username and email pair, the username will be ignored. This also impacts where emails are sent to.

adjutant.identity.auth Are the credentials that Adjutant uses to talk to Keystone, and the various other OpenStack services.

adjutant.identity.role_mapping defines which roles can modify other roles. In the default configuration a user who has the role project_mod will not be able to modify any of the roles for a user with the project_admin role.

API group

Controls which DelegateAPIs are enabled, and what some of their configuration may be.

Notifications group

Default settings around what notifications should do during the task workflows.

Workflow group

adjutant.workflow.task_defaults Represents the default settings for all tasks unless otherwise overridden for individual tasks in adjutant.workflow.tasks.

Default action settings. adjutant.workflow.action_defaults Are the default settings for each action and can be overriden on a per task basis via adjutant.workflow.tasks.<my_task>.actions.

Email and notification templates

Additional templates can be placed in /etc/adjutant/templates/ and will be loaded in automatically. A plain text template and an HTML template can be specified separately. The context for this will include the task object and a dictionary containing the action objects.