Let Pillar extensions register new roles.

These will be available via the app.user_roles property.
This commit is contained in:
2017-06-15 11:06:01 +02:00
parent cdb148fc0d
commit 13b67702b4
2 changed files with 25 additions and 0 deletions

View File

@@ -32,6 +32,9 @@ class PillarExtension(object, metaclass=abc.ABCMeta):
# List of Celery task modules introduced by this extension.
celery_task_modules: typing.List[str] = []
# Set of user roles used/introduced by this extension.
user_roles: typing.Set[str] = set()
@property
@abc.abstractmethod
def name(self):