api

package
v1.10.0 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2018 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Certificate file names that will be generated by Dashboard
	DashboardCertName = "dashboard.crt"
	DashboardKeyName  = "dashboard.key"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Creator

type Creator interface {
	// GenerateKey generates certificate key
	GenerateKey() interface{}
	// GenerateCertificate generates certificate
	GenerateCertificate(key interface{}) []byte
	// StoreCertificates saves certificates in a given path
	StoreCertificates(path string, key interface{}, certBytes []byte)
	// KeyCertPEMBytes converts the key and cert to PEM format
	KeyCertPEMBytes(key interface{}, certBytes []byte) (keyPEM []byte, certPEM []byte, err error)
	// GetKeyFileName returns certificate key file name
	GetKeyFileName() string
	// GetCertFileName returns certificate file name
	GetCertFileName() string
}

Creator is responsible for preparing and generating certificates.

type Manager

type Manager interface {
	// GetCertificates loads existing certificates or generates self-signed certificates.
	GetCertificates() (tls.Certificate, error)
}

Manager is responsible for generating and storing self-signed certificates that can be used by Dashboard to serve over HTTPS.

Jump to

Keyboard shortcuts

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