Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BackendConf ¶
type BackendConf struct {
Name string `yaml:"name"`
Domain string `yaml:"domain"`
IP string `yaml:"ip"`
Port int `yaml:"port"`
IfModifiedValidation int `yaml:"ifmodified_validation"`
CertFile string `yaml:"cert"`
KeyFile string `yaml:"key"`
}
BackendConf is the configuration for a website we cache for
func (BackendConf) IsValid ¶
func (bc BackendConf) IsValid() (bool, string)
IsValid checks the validity of a backend config
type CDN ¶
type CDN struct {
// contains filtered or unexported fields
}
CDN represents the CDN ojbect
type Conf ¶
type Conf struct {
API api.Conf `yaml:"api"`
Cache cache.Conf `yaml:"cache"`
HTTP HTTPConf `yaml:"http"`
HTTPS HTTPConf `yaml:"https"`
}
Conf is the cdn configuration
func DefaultConf ¶
func DefaultConf() Conf
DefaultConf returns a HTTP configuration with some defaults
type HTTPConf ¶
type HTTPConf struct {
Address string `yaml:"address"`
Port int `yaml:"port"`
Backends []BackendConf `yaml:"backends"`
}
HTTPConf is the configuration for the http server
func DefaultHTTPConf ¶
func DefaultHTTPConf() HTTPConf
DefaultHTTPConf returns a HTTP configuration with some defaults
func DefaultHTTPSConf ¶
func DefaultHTTPSConf() HTTPConf
DefaultHTTPSConf returns a HTTPS configuration with some defaults
Click to show internal directories.
Click to hide internal directories.