Skip to content

Commit

Permalink
Merge pull request #23180 from roberthbailey/dead-code
Browse files Browse the repository at this point in the history
Auto commit by PR queue bot
(cherry picked from commit f2d1499)
  • Loading branch information
k8s-merge-robot authored and eparis committed Mar 24, 2016
1 parent fc63dff commit 928f581
Show file tree
Hide file tree
Showing 6 changed files with 1 addition and 67 deletions.
10 changes: 0 additions & 10 deletions cluster/aws/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -1577,16 +1577,6 @@ function ssh-to-node {
done
}

# Restart the kube-proxy on a node ($1)
function restart-kube-proxy {
ssh-to-node "$1" "sudo /etc/init.d/kube-proxy restart"
}

# Restart the kube-apiserver on a node ($1)
function restart-apiserver {
ssh-to-node "$1" "sudo /etc/init.d/kube-apiserver restart"
}

# Perform preparations required to run e2e tests
function prepare-e2e() {
# (AWS runs detect-project, I don't think we need to anything)
Expand Down
14 changes: 0 additions & 14 deletions cluster/gce/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -1347,20 +1347,6 @@ function ssh-to-node {
gcloud compute ssh --ssh-flag="-o LogLevel=quiet" --project "${PROJECT}" --zone="${ZONE}" "${node}" --command "${cmd}"
}

# Restart the kube-proxy on a node ($1)
function restart-kube-proxy {
if [[ "${OS_DISTRIBUTION}" == "trusty" ]]; then
ssh-to-node "$1" "sudo initctl restart kube-proxy"
else
ssh-to-node "$1" "sudo /etc/init.d/kube-proxy restart"
fi
}

# Restart the kube-apiserver on a node ($1)
function restart-apiserver {
ssh-to-node "$1" "sudo docker ps | grep /kube-apiserver | cut -d ' ' -f 1 | xargs sudo docker kill"
}

# Perform preparations required to run e2e tests
function prepare-e2e() {
detect-project
Expand Down
14 changes: 1 addition & 13 deletions cluster/gke/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ function test-setup() {
"${KUBE_ROOT}/cluster/kube-up.sh"

detect-nodes >&2

# At this point, CLUSTER_NAME should have been used, so its value is final.
NODE_TAG=$($GCLOUD compute instances describe ${NODE_NAMES[0]} --project="${PROJECT}" --zone="${ZONE}" | grep -o "gke-${CLUSTER_NAME}-.\{8\}-node" | head -1)
OLD_NODE_TAG="k8s-${CLUSTER_NAME}-node"
Expand Down Expand Up @@ -272,18 +272,6 @@ function ssh-to-node() {
gcloud compute ssh --ssh-flag="-o LogLevel=quiet" --project "${PROJECT}" --zone="${ZONE}" "${node}" --command "${cmd}"
}

# Restart the kube-proxy on a node ($1)
function restart-kube-proxy() {
echo "... in gke:restart-kube-proxy()" >&2
ssh-to-node "$1" "sudo /etc/init.d/kube-proxy restart"
}

# Restart the kube-proxy on master ($1)
function restart-apiserver() {
echo "... in gke:restart-apiserver()" >&2
ssh-to-node "$1" "sudo docker ps | grep /kube-apiserver | cut -d ' ' -f 1 | xargs sudo docker kill"
}

# Execute after running tests to perform any required clean-up. This is called
# from hack/e2e.go. This calls kube-down, so the cluster still exists when this
# is called.
Expand Down
10 changes: 0 additions & 10 deletions cluster/libvirt-coreos/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -348,16 +348,6 @@ function ssh-to-node {
ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o ControlMaster=no "core@$machine" "$cmd"
}

# Restart the kube-proxy on a node ($1)
function restart-kube-proxy {
ssh-to-node "$1" "sudo systemctl restart kube-proxy"
}

# Restart the apiserver
function restart-apiserver {
ssh-to-node "$1" "sudo systemctl restart kube-apiserver"
}

# Perform preparations required to run e2e tests
function prepare-e2e() {
echo "libvirt-coreos doesn't need special preparations for e2e tests" 1>&2
Expand Down
10 changes: 0 additions & 10 deletions cluster/mesos/docker/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -334,16 +334,6 @@ function ssh-to-node {
echo "TODO: ssh-to-node" 1>&2
}

# Restart the kube-proxy on a node ($1)
function restart-kube-proxy {
echo "TODO: restart-kube-proxy" 1>&2
}

# Restart the apiserver
function restart-apiserver {
echo "TODO: restart-apiserver" 1>&2
}

# Waits for a kube-system pod (of the provided name) to have the phase/status "Running".
function cluster::mesos::docker::await_ready {
local pod_name="$1"
Expand Down
10 changes: 0 additions & 10 deletions cluster/vagrant/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -377,16 +377,6 @@ function ssh-to-node {
vagrant ssh "${machine}" -c "${cmd}"
}

# Restart the kube-proxy on a node ($1)
function restart-kube-proxy {
ssh-to-node "$1" "sudo systemctl restart kube-proxy"
}

# Restart the apiserver
function restart-apiserver {
ssh-to-node "$1" "sudo systemctl restart kube-apiserver"
}

# Perform preparations required to run e2e tests
function prepare-e2e() {
echo "Vagrant doesn't need special preparations for e2e tests" 1>&2
Expand Down

0 comments on commit 928f581

Please sign in to comment.