mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 19:31:44 +00:00
parent
27a18684bf
commit
223fb6e610
@ -49,7 +49,7 @@ for (( i=0; i<${#MINION_NAMES[@]}; i++)); do
|
||||
fi
|
||||
|
||||
# Make sure the kubelet is healthy
|
||||
if [ "$(curl --insecure -sw '%{http_code}' --user ${user}:${passwd} https://${KUBE_MASTER_IP}/proxy/minion/${MINION_NAMES[$i]}/healthz)" != "200" ]; then
|
||||
if [ "$(curl --insecure --user ${user}:${passwd} https://${KUBE_MASTER_IP}/proxy/minion/${MINION_NAMES[$i]}/healthz)" != "ok" ]; then
|
||||
echo "Kubelet failed to install on ${MINION_NAMES[$i]}. Your cluster is unlikely to work correctly."
|
||||
echo "Please run ./cluster/kube-down.sh and re-create the cluster. (sorry!)"
|
||||
exit 1
|
||||
|
@ -31,6 +31,7 @@ import (
|
||||
"time"
|
||||
|
||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/api"
|
||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/healthz"
|
||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/httplog"
|
||||
"github.com/golang/glog"
|
||||
"github.com/google/cadvisor/info"
|
||||
@ -82,7 +83,7 @@ func NewServer(host HostInterface, updates chan<- interface{}) Server {
|
||||
|
||||
// InstallDefaultHandlers registers the set of supported HTTP request patterns with the mux
|
||||
func (s *Server) InstallDefaultHandlers() {
|
||||
s.mux.HandleFunc("/healthz", s.handleHealth)
|
||||
healthz.InstallHandler(s.mux)
|
||||
s.mux.HandleFunc("/container", s.handleContainer)
|
||||
s.mux.HandleFunc("/containers", s.handleContainers)
|
||||
s.mux.HandleFunc("/podInfo", s.handlePodInfo)
|
||||
@ -97,10 +98,6 @@ func (s *Server) error(w http.ResponseWriter, err error) {
|
||||
http.Error(w, fmt.Sprintf("Internal Error: %v", err), http.StatusInternalServerError)
|
||||
}
|
||||
|
||||
// handleHealth handles health checking requests against the Kubelet
|
||||
func (s *Server) handleHealth(w http.ResponseWriter, req *http.Request) {
|
||||
}
|
||||
|
||||
// handleContainer handles container requests against the Kubelet
|
||||
func (s *Server) handleContainer(w http.ResponseWriter, req *http.Request) {
|
||||
defer req.Body.Close()
|
||||
|
Loading…
Reference in New Issue
Block a user