Conductor Documentation

Policy Triggers

policy_triggers specify the implementation of actions that are invoked by policies, and declare the properties that define a trigger’s behavior.

Declaration

The policy_triggers section is a hash in which each item in the hash represents an policy trigger.

policy_triggers:
  # my_definitions.policy_triggers.my_trigger1 is the policy trigger name
  my_definitions.policy_triggers.my_trigger1:
    ...
  my_trigger2:
    ...

Schema

Keyname Required Type Description
source yes string The policy trigger implementation source (a URL or a path relative to the blueprint root directory).
parameters no dict Optional parameters schema for the policy trigger.

Example

policy_triggers:

  my_webhook_trigger:

    source: policy_trigger/webhook_trigger.clj

    properties:
      webhook_endpoint:
        description: >
          URL for making a POST HTTP request to
      webhook_body:
        description: >
          request body (serialized to JSON)
        default: {}

Built-in Policy Triggers

The following policy triggers are defined in types.yaml.

cloudify.policies.triggers.execute_workflow

Parameters:

You can find the implementation for this trigger on github. It builds the HTTP request to the Manager REST service and makes the actual REST call using the clj-http clojure library.

Usage

This section describes how to define a policy trigger. To use policy triggers with policies, see the Groups specification.