etr  4.0-pre
Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
etr.plugins.resources.Plugin Class Reference

Resources plugin. More...

Public Member Functions

def __init__ (self, ctx)
 Initialize and configure resoures plugin. More...
 
def setup (self, ctx)
 Acquire resources. More...
 
def teardown (self, ctx)
 Release allocated resources. More...
 

Static Public Member Functions

def add_options (parser)
 Add --resource-host option. More...
 

Static Public Attributes

int order = 100
 
string config_schema
 

Detailed Description

Resources plugin.

Configuration schema:

Examples

resources: name # Given resource name type "type" # Requested type tags [ "tag", "tag" ] # Requested matching tags (optional)

Constructor & Destructor Documentation

◆ __init__()

def etr.plugins.resources.Plugin.__init__ (   self,
  ctx 
)

Initialize and configure resoures plugin.

Member Function Documentation

◆ add_options()

def etr.plugins.resources.Plugin.add_options (   parser)
static

Add --resource-host option.

◆ setup()

def etr.plugins.resources.Plugin.setup (   self,
  ctx 
)

Acquire resources.

◆ teardown()

def etr.plugins.resources.Plugin.teardown (   self,
  ctx 
)

Release allocated resources.

Member Data Documentation

◆ config_schema

string etr.plugins.resources.Plugin.config_schema
static
Initial value:
= """
type: object
additionalProperties: False
patternProperties:
"^[a-zA-Z][a-zA-Z0-9_-]*$":
type: object
additionalProperties: false
required: [ "type" ]
properties:
type:
type: string
tags:
type: array
items:
type: string
uniqueItems: True
"""

◆ order

int etr.plugins.resources.Plugin.order = 100
static

The documentation for this class was generated from the following file: