Parcourir la source

Merge pull request #62 from philips/re-add-etcd-to-banner

fix(client_handlers): re-add etcd name to banner
Xiang Li il y a 12 ans
Parent
commit
c109da4b43
1 fichiers modifiés avec 2 ajouts et 1 suppressions
  1. 2 1
      client_handlers.go

+ 2 - 1
client_handlers.go

@@ -4,6 +4,7 @@ import (
 	"github.com/coreos/etcd/store"
 	"net/http"
 	"strconv"
+	"fmt"
 	"time"
 )
 
@@ -234,7 +235,7 @@ func MachinesHttpHandler(w http.ResponseWriter, req *http.Request) {
 // Handler to return the current version of etcd
 func VersionHttpHandler(w http.ResponseWriter, req *http.Request) {
 	w.WriteHeader(http.StatusOK)
-	w.Write([]byte(releaseVersion))
+	w.Write([]byte(fmt.Sprintf("etcd %s", releaseVersion)))
 }
 
 // Handler to return the basic stats of etcd