WardrikDaemon.Config.Notify (wardrik_daemon v0.1.0-rc.1)

Copy Markdown

Reads config.yaml's notify: the targets agents' notices go to, each by a name of your own.

notify:
  ops: {channel: slack, room: "#ops", approvers: ["@maria"]}
  audit: {webhook: {url: https://hooks.example.com/wardrik, secret: "${WEBHOOK_SECRET}"}}

A target is one of:

  • a room - channel, one of channels, its room, and optional approvers.
  • a webhook - webhook, with url and an optional secret.

A target's name can't hold :, which names a channel's room. A target tells the deployment's own org's agents unless orgs says otherwise. See Wardrik.Notify.

Summary

Functions

Returns the targets section names, as Wardrik's :notify option takes them, telling org's agents. channels are the channels' names.

Functions

read(section, org, channels)

@spec read(map() | nil, String.t(), [String.t()]) ::
  {:ok, keyword()} | {:error, String.t()}

Returns the targets section names, as Wardrik's :notify option takes them, telling org's agents. channels are the channels' names.