From d72cfc9d57dba1c432a5cc4f0fc2696f4e9d1b0e Mon Sep 17 00:00:00 2001 From: Kapunahele Wong Date: Wed, 27 Nov 2019 13:42:06 -0500 Subject: [PATCH] docs: remove deployment section on golang because of errors (#34099) The golang section was recently added to the deployment guide but has been reported as returning errors, where it had previously worked. After discussion and testing with Stephen Fluin, we are removing this section because of inconsistency in functionality. PR Close #34099 --- aio/content/guide/deployment.md | 30 ------------------------------ 1 file changed, 30 deletions(-) diff --git a/aio/content/guide/deployment.md b/aio/content/guide/deployment.md index 093233c316..34d36d3af8 100644 --- a/aio/content/guide/deployment.md +++ b/aio/content/guide/deployment.md @@ -201,36 +201,6 @@ modified to serve `index.html`: try_files $uri $uri/ /index.html; ``` - -* [Golang](https://golang.org/): create a Golang server using ([gorilla/mux](https://github.com/gorilla/mux)) with a basic Golang file that configures the server `main.go`: - - ``` go - package main - - import ( - "net/http" - "os" - "github.com/gorilla/mux" - ) - var httpPort = "80" - var folderDist = "./dist" // ng build output folder - - func serverHandler(w http.ResponseWriter, r *http.Request) { - if _, err := os.Stat(folderDist + r.URL.Path); err != nil { - http.ServeFile(w, r, folderDist+"/index.html") - return - } - http.ServeFile(w, r, folderDist+r.URL.Path) - } - - func main() { - r := mux.NewRouter() - r.NotFoundHandler = r.NewRoute().HandlerFunc(serverHandler).GetHandler() - http.Handle("/", r) - http.ListenAndServe(":"+httpPort, nil) - } - ``` - * [Ruby](https://www.ruby-lang.org/): create a Ruby server using ([sinatra](http://sinatrarb.com/)) with a basic Ruby file that configures the server `server.rb`: ``` ruby