build: golang.org/x/build/internal/https Index | Files

package https

import "golang.org/x/build/internal/https"

Package https contains helpers for starting an HTTPS server.

Index

Package Files

https.go

func ListenAndServe Uses

func ListenAndServe(handler http.Handler, opt *Options) error

ListenAndServe serves the given handler by HTTPS (and HTTP, redirecting to HTTPS) using the provided options.

type Options Uses

type Options struct {
    // Addr specifies the host and port the server should listen on.
    Addr string

    // AutocertCacheBucket specifies the name of the GCS bucket for
    // Let’s Encrypt to use. If this is not specified, then HTTP traffic is
    // served on Addr.
    AutocertCacheBucket string
}

Options are the configuration parameters for the HTTP(S) server.

Package https imports 11 packages (graph) and is imported by 1 packages. Updated 2017-11-18. Refresh now. Tools for package owners.