Documentation ¶
Overview ¶
Package https provides a helper function to set up an HTTPS server derived from the current environment.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ListenAndServe ¶
func ListenAndServe(ready chan<- struct{}, serverName string)
ListenAndServe serves the http.DefaultServeMux by HTTPS (and HTTP, redirecting to HTTPS), configured using the server command line flags.
If running on GCE and the -letscache flag is *not* specified, ListenAndServe will configure a Let's Encrypt cache that stores its data in the Cloud Storage bucket specified by the "letsencrypt-bucket" instance attribute in the Compute Engine Metadata server.
The given channel, if any, is closed when the TCP listener has succeeded. It may be used to signal that the server is ready to start serving requests.
ListenAndServe does not return. It exits the program when the server is shut down (via SIGTERM or due to an error) and calls shutdown.Shutdown.
Types ¶
This section is empty.