Send notifications and share information about Morpheus Processes

Morpheus performs a wide array of operations in its role as your Cloud Management Platform and though there are some ways to send notifications, for example, in a task within a workflow, the majority of operations which run day-to-day (and often unattended in the background), do not provide for this. What if you could configure notifications on - and share information about - all Morpheus operations?

With Dozer, Morpheus users can do exactly this; choose to watch specific Morpheus processes and events. Using simple YAML configuration, Dozer facilitates the creation of Webhooks which when triggered, send notifications and share information about Morpheus processes, to your external applications.

Why not watch the demonstration opposite where Dozer is configured to send notifications about Morpheus to Slack?

Get started with Dozer

Dozer can be installed and configured in minutes...

Install Dozer

Dozer is available for Linux and Mac OS and can be found on Github. It may be hosted on the same server as the Morpheus Appliance or on a seprate VM.

Download the latest release to your server and unpack the gzipped package.

wget https://github.com/spoonboy-io/dozer/releases/download/v0.0.1/dozer_0.0.1_Linux_x86_64.tar.gz
tar -xvf dozer_0.0.1_Linux_x86_64.tar.gz

Run the Dozer application

./dozer

Configure MySQL Access

Dozer polls the Morpheus MySQL database so needs access. It's recommended to create an additional MySQL user, with grants limited to select (read) only.

Create a `mysql.env` file in sthe same directory as Dozer and add your database configuration.

## MySQL Config
MYSQL_SERVER=morpheus-server
MYSQL_USER=dozer
MYSQL_PASSWORD=Password123?

## Optional Dozer Config
#POLL_INTERVAL_SECONDS=3    

Configure a Webhook

Create `webhook.yaml` file in the same directory as Dozer and then add a Webhook.

In the example below, Dozer will watch the Morpheus process type 'localWorkflow' and send notifications to Slack.

- webhook:
    description: Task finished notification to Slack
    url: https://hooks.slack.com/services/T03XXXBXXQ/B03MXXXXJVC/3FGjXXXXXXXXmUTca
    method: POST
    requestBody: |
        {"text":"Task: '{{.TaskName}}' created by '{{.CreatedBy}}' has completed with status: '{{.Status}}'. Happy Days!"}
    token:
    triggers:
        processType: localWorkflow
golang morpheus webhooks notification process