Documentation ¶
Index ¶
- Constants
- Variables
- func ConfigureResolver(domains []string, port int) error
- func GeneratePumaDevCertificateAuthority(certPath string, keyPath string) error
- func NewCertCache() *certCache
- func SetupOurCert() error
- func Stop() error
- func TrustCert(cert string) error
- type App
- type AppPool
- type DNSResponder
- type Events
- type HTTPServer
Constants ¶
View Source
const ( Booting = iota Running Dead )
View Source
const DefaultThreads = 5
View Source
const SupportDir = "~/.puma-dev-ssl"
Variables ¶
View Source
var CACert *tls.Certificate
View Source
var ErrUnexpectedExit = errors.New("unexpected exit")
View Source
var ErrUnknownApp = errors.New("unknown app")
Functions ¶
func ConfigureResolver ¶
func NewCertCache ¶
func NewCertCache() *certCache
func SetupOurCert ¶
func SetupOurCert() error
Types ¶
type App ¶
type App struct { Name string Scheme string Host string Port int Command *exec.Cmd Public bool Events *Events // contains filtered or unexported fields }
func (*App) SetAddress ¶
func (*App) WaitTilReady ¶
type AppPool ¶
type AppPool struct { Dir string IdleTime time.Duration Debug bool Events *Events AppClosed func(*App) // contains filtered or unexported fields }
func (*AppPool) FindAppByDomainName ¶
type DNSResponder ¶
type DNSResponder struct { Address string Domains []string // contains filtered or unexported fields }
func NewDNSResponder ¶
func NewDNSResponder(address string, domains []string) *DNSResponder
func (*DNSResponder) Serve ¶
func (d *DNSResponder) Serve() error
type HTTPServer ¶
type HTTPServer struct { Address string TLSAddress string Pool *AppPool Debug bool Events *Events IgnoredStaticPaths []string Domains []string // contains filtered or unexported fields }
func (*HTTPServer) AppClosed ¶
func (h *HTTPServer) AppClosed(app *App)
func (*HTTPServer) Serve ¶
func (h *HTTPServer) Serve() error
func (*HTTPServer) ServeHTTP ¶
func (h *HTTPServer) ServeHTTP(w http.ResponseWriter, req *http.Request)
func (*HTTPServer) ServeTLS ¶
func (h *HTTPServer) ServeTLS() error
func (*HTTPServer) Setup ¶
func (h *HTTPServer) Setup()
Source Files ¶
Click to show internal directories.
Click to hide internal directories.