Created
October 16, 2017 00:10
-
-
Save hiyosi/4cb7a0334c84a133061861d08d721ccf to your computer and use it in GitHub Desktop.
This file contains 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
func main() { | |
r := mux.NewRouter() | |
r.HandleFunc("/foo", someHandler) | |
var err error | |
listener, err := net.Listen("unix", "/var/run/fcgi.sock") | |
if err != nil { | |
log.Fatal(err) | |
} | |
defer listener.Close() | |
err = fcgi.Serve(listener, r) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment