Documentation ¶
Index ¶
- Variables
- func Enable(caddyfile string, player TemplateFunc)
- func GetConfigPaths() [][]string
- func GetInstance() *caddy.Instance
- func GetMaintenanceRoot() (string, error)
- func GetPathes() []string
- func RegisterPluginTemplate(fn TemplateFunc, watchConfigPath []string, pathes ...string) error
- func Restart() error
- func ServiceReady(name string) bool
- func Start() error
- func StartWithFastRestart() (chan bool, error)
- func Stop() error
- type Caddy
- type SiteConf
- type TemplateFunc
Constants ¶
This section is empty.
Variables ¶
View Source
var ( DefaultCaUrl = "https://acme-v02.api.letsencrypt.org/directory" DefaultCaStagingUrl = "https://acme-staging-v02.api.letsencrypt.org/directory" )
View Source
var (
FuncMap = template.FuncMap{
"urls": internalURLFromServices,
"serviceAddress": addressFromService,
}
)
Functions ¶
func GetConfigPaths ¶ added in v1.5.0
func GetConfigPaths() [][]string
func GetInstance ¶
func GetMaintenanceRoot ¶
func RegisterPluginTemplate ¶
func RegisterPluginTemplate(fn TemplateFunc, watchConfigPath []string, pathes ...string) error
RegisterPluginTemplate adds a TemplateFunc to be called for each plugin
func ServiceReady ¶
func StartWithFastRestart ¶ added in v1.4.1
Types ¶
type Caddy ¶
type Caddy struct {
// contains filtered or unexported fields
}
Caddy contains the templates and functions for building a dynamic caddyfile
func (*Caddy) GetTemplate ¶
type SiteConf ¶
type SiteConf struct { *install.ProxyConfig // Parsed values from proto oneOf TLS string TLSCert string TLSKey string // Parsed External host if any ExternalHost string // Custom Root for this site WebRoot string }
func SiteConfFromProxyConfig ¶
func SiteConfFromProxyConfig(pc *install.ProxyConfig) (SiteConf, error)
func SitesToCaddyConfigs ¶
func SitesToCaddyConfigs(sites []*install.ProxyConfig) (caddySites []SiteConf, er error)
type TemplateFunc ¶
TemplateFunc is a function providing a stringer
func GetTemplates ¶
func GetTemplates() []TemplateFunc
Click to show internal directories.
Click to hide internal directories.