jobs

package
v0.0.0-...-fc93924 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 23, 2018 License: MIT Imports: 10 Imported by: 1

Documentation

Overview

Package jobs defines a few cron jobs that can be scheduled to run.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RegionUsage

type RegionUsage struct {
	Sess *session.Session
	// contains filtered or unexported fields
}

RegionUsage represents the various resource usage of a region.

type SlackAttachment

type SlackAttachment struct {
	Fallback   string                 `json:"fallback,omitempty"`
	Color      string                 `json:"color,omitempty"`
	PreText    string                 `json:"pretext,omitempty"`
	AuthorName string                 `json:"author_name,omitempty"`
	AuthorLink string                 `json:"author_link,omitempty"`
	AuthorIcon string                 `json:"author_icon,omitempty"`
	Title      string                 `json:"title,omitempty"`
	TitleLink  string                 `json:"title_link,omitempty"`
	Text       string                 `json:"text,omitempty"`
	Fields     []SlackAttachmentField `json:"fields,omitempty"`
	ImageURL   string                 `json:"image_url,omitempty"`
	ThumbURL   string                 `json:"thumb_url,omitempty"`
	Footer     string                 `json:"footer,omitempty"`
	FooterIcon string                 `json:"footer_icon,omitempty"`
	TS         int64                  `json:"ts,omitempty"`
}

SlackAttachment defines a slack attachment

type SlackAttachmentField

type SlackAttachmentField struct {
	Title string `json:"title"`
	Value string `json:"value"`
	Short bool   `json:"short"`
}

SlackAttachmentField defines a slack attachment field

type SlackAttachments

type SlackAttachments struct {
	Attacments []SlackAttachment `json:"attachments"`
}

SlackAttachments defines slack attachments

type SlackJob

type SlackJob struct {
	// contains filtered or unexported fields
}

SlackJob defines a slack cron job

func NewSlackJob

func NewSlackJob(regions []string, webhookURL string) SlackJob

NewSlackJob creates a new slack cron job.

func (SlackJob) Run

func (o SlackJob) Run()

Run runs the slack cron job.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL