dashboard

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Oct 3, 2019 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// MainTemplateName is the main template
	MainTemplateName = "main.gohtml"
	// HeadTemplateName contains styles and meta info
	HeadTemplateName = "head.gohtml"
	// NavbarTemplateName contains the navbar
	NavbarTemplateName = "navbar.gohtml"
	// PreambleTemplateName contains an empty preamble that can be overridden
	PreambleTemplateName = "preamble.gohtml"
	// DashboardTemplateName contains the content of the dashboard
	DashboardTemplateName = "dashboard.gohtml"
	// FooterTemplateName contains the footer
	FooterTemplateName = "footer.gohtml"
	// CheckDetailsTemplateName is a page for rendering details about a given check
	CheckDetailsTemplateName = "check-details.gohtml"
)

Variables

This section is empty.

Functions

func GetAssetBox

func GetAssetBox() *packr.Box

GetAssetBox returns a binary-friendly set of assets packaged from disk

func GetBaseTemplate

func GetBaseTemplate(name string) (*template.Template, error)

GetBaseTemplate puts together the dashboard template. Individual pieces can be overridden before rendering.

func GetMarkdownBox

func GetMarkdownBox() *packr.Box

GetMarkdownBox returns a binary-friendly set of markdown files with error details

func GetRouter

func GetRouter(port int, basePath string, vpaLabels map[string]string, excludeContainers string) *mux.Router

GetRouter returns a mux router serving all routes necessary for the dashboard

func GetTemplateBox

func GetTemplateBox() *packr.Box

GetTemplateBox returns a binary-friendly set of templates for rendering the dash

func MainHandler

func MainHandler(w http.ResponseWriter, r *http.Request, vpaData summary.Summary, basePath string)

MainHandler gets template data and renders the dashboard with it.

Types

This section is empty.

Jump to

Keyboard shortcuts

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