Created
July 10, 2016 22:51
-
-
Save sinmetal/89c10a14daef4becb184feb58d8f5279 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"net/http" | |
) | |
func init() { | |
http.HandleFunc("/.well-known/acme-challenge/", handlerLetsencypt) | |
} | |
func handlerLetsencypt(w http.ResponseWriter, r *http.Request) { | |
w.Header().Set("Content-Type", "text.plain; charset=utf-8") | |
w.WriteHeader(http.StatusOK) | |
w.Write([]byte("Your Code") | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment