Skip to content

Commit

Permalink
Remove /build endpoint (#4875)
Browse files Browse the repository at this point in the history
  • Loading branch information
aledbf authored Dec 31, 2019
1 parent f0f9618 commit 8db541e
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions cmd/nginx/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ limitations under the License.
package main

import (
"encoding/json"
"fmt"
"math/rand"
"net/http"
Expand Down Expand Up @@ -139,7 +138,6 @@ func main() {

registerHealthz(nginx.HealthPath, ngx, mux)
registerMetrics(reg, mux)
registerHandlers(mux)

go startHTTPServer(conf.ListenPorts.Health, mux)

Expand Down Expand Up @@ -253,14 +251,6 @@ func handleFatalInitError(err error) {
err)
}

func registerHandlers(mux *http.ServeMux) {
mux.HandleFunc("/build", func(w http.ResponseWriter, r *http.Request) {
w.WriteHeader(http.StatusOK)
b, _ := json.Marshal(version.String())
w.Write(b)
})
}

func registerHealthz(healthPath string, ic *controller.NGINXController, mux *http.ServeMux) {
// expose health check endpoint (/healthz)
healthz.InstallPathHandler(mux,
Expand Down

0 comments on commit 8db541e

Please sign in to comment.