serve wildcard certificate files
This commit is contained in:
15
http/server.go
Normal file
15
http/server.go
Normal file
@ -0,0 +1,15 @@
|
||||
package http
|
||||
|
||||
import (
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func ServeCertificate() {
|
||||
http.HandleFunc("/server.key", func(w http.ResponseWriter, r *http.Request) {
|
||||
http.ServeFile(w, r, "/certs/server.key")
|
||||
})
|
||||
http.HandleFunc("/server.pem", func(w http.ResponseWriter, r *http.Request) {
|
||||
http.ServeFile(w, r, "/certs/server.pem")
|
||||
})
|
||||
http.ListenAndServe(":9229", nil)
|
||||
}
|
Reference in New Issue
Block a user