From 5ff30086e42fc6efe533bf895eff3e61586a1445 Mon Sep 17 00:00:00 2001 From: Jordan Liggitt Date: Thu, 9 Mar 2017 13:12:17 -0500 Subject: [PATCH] Switch to proxy subresource --- .../cluster-administration/access-cluster.md | 20 +++++++++---------- docs/getting-started-guides/clc.md | 6 +++--- .../ubuntu/installation.md | 8 ++++---- docs/user-guide/docker-cli-to-kubectl.md | 10 +++++----- docs/user-guide/update-demo/local/script.js | 2 +- 5 files changed, 23 insertions(+), 23 deletions(-) diff --git a/docs/concepts/cluster-administration/access-cluster.md b/docs/concepts/cluster-administration/access-cluster.md index 27942f2175..724e8971ed 100644 --- a/docs/concepts/cluster-administration/access-cluster.md +++ b/docs/concepts/cluster-administration/access-cluster.md @@ -233,30 +233,30 @@ with the `kubectl cluster-info` command: $ kubectl cluster-info Kubernetes master is running at https://104.197.5.247 - elasticsearch-logging is running at https://104.197.5.247/api/v1/proxy/namespaces/kube-system/services/elasticsearch-logging - kibana-logging is running at https://104.197.5.247/api/v1/proxy/namespaces/kube-system/services/kibana-logging - kube-dns is running at https://104.197.5.247/api/v1/proxy/namespaces/kube-system/services/kube-dns - grafana is running at https://104.197.5.247/api/v1/proxy/namespaces/kube-system/services/monitoring-grafana - heapster is running at https://104.197.5.247/api/v1/proxy/namespaces/kube-system/services/monitoring-heapster + elasticsearch-logging is running at https://104.197.5.247/api/v1/namespaces/kube-system/services/elasticsearch-logging/proxy + kibana-logging is running at https://104.197.5.247/api/v1/namespaces/kube-system/services/kibana-logging/proxy + kube-dns is running at https://104.197.5.247/api/v1/namespaces/kube-system/services/kube-dns/proxy + grafana is running at https://104.197.5.247/api/v1/namespaces/kube-system/services/monitoring-grafana/proxy + heapster is running at https://104.197.5.247/api/v1/namespaces/kube-system/services/monitoring-heapster/proxy ``` This shows the proxy-verb URL for accessing each service. For example, this cluster has cluster-level logging enabled (using Elasticsearch), which can be reached -at `https://104.197.5.247/api/v1/proxy/namespaces/kube-system/services/elasticsearch-logging/` if suitable credentials are passed, or through a kubectl proxy at, for example: -`http://localhost:8080/api/v1/proxy/namespaces/kube-system/services/elasticsearch-logging/`. +at `https://104.197.5.247/api/v1/namespaces/kube-system/services/elasticsearch-logging/proxy/` if suitable credentials are passed, or through a kubectl proxy at, for example: +`http://localhost:8080/api/v1/namespaces/kube-system/services/elasticsearch-logging/proxy/`. (See [above](#accessing-the-cluster-api) for how to pass credentials or use kubectl proxy.) #### Manually constructing apiserver proxy URLs As mentioned above, you use the `kubectl cluster-info` command to retrieve the service's proxy URL. To create proxy URLs that include service endpoints, suffixes, and parameters, you simply append to the service's proxy URL: -`http://`*`kubernetes_master_address`*`/api/v1/proxy/namespaces/`*`namespace_name`*`/services/`*`service_name[:port_name]`* +`http://`*`kubernetes_master_address`*`/api/v1/namespaces/`*`namespace_name`*`/services/`*`service_name[:port_name]`*`/proxy` If you haven't specified a name for your port, you don't have to specify *port_name* in the URL ##### Examples - * To access the Elasticsearch service endpoint `_search?q=user:kimchy`, you would use: `http://104.197.5.247/api/v1/proxy/namespaces/kube-system/services/elasticsearch-logging/_search?q=user:kimchy` - * To access the Elasticsearch cluster health information `_cluster/health?pretty=true`, you would use: `https://104.197.5.247/api/v1/proxy/namespaces/kube-system/services/elasticsearch-logging/_cluster/health?pretty=true` + * To access the Elasticsearch service endpoint `_search?q=user:kimchy`, you would use: `http://104.197.5.247/api/v1/namespaces/kube-system/services/elasticsearch-logging/proxy/_search?q=user:kimchy` + * To access the Elasticsearch cluster health information `_cluster/health?pretty=true`, you would use: `https://104.197.5.247/api/v1/namespaces/kube-system/services/elasticsearch-logging/proxy/_cluster/health?pretty=true` ```json { diff --git a/docs/getting-started-guides/clc.md b/docs/getting-started-guides/clc.md index 726fe71ac4..07b04b68c7 100644 --- a/docs/getting-started-guides/clc.md +++ b/docs/getting-started-guides/clc.md @@ -272,8 +272,8 @@ We install two UIs on Kubernetes. The original KubeUI and [the newer kube dashboard](/docs/user-guide/ui/). When you create a cluster, the script should output URLs for these interfaces like this: -KubeUI is running at ```https://${MASTER_IP}:6443/api/v1/proxy/namespaces/kube-system/services/kube-ui``` -kubernetes-dashboard is running at ```https://${MASTER_IP}:6443/api/v1/proxy/namespaces/kube-system/services/kubernetes-dashboard``` +KubeUI is running at ```https://${MASTER_IP}:6443/api/v1/namespaces/kube-system/services/kube-ui/proxy``` +kubernetes-dashboard is running at ```https://${MASTER_IP}:6443/api/v1/namespaces/kube-system/services/kubernetes-dashboard/proxy``` Note on Authentication to the UIs: The cluster is set up to use basic authentication for the user _admin_. Hitting the url at @@ -316,7 +316,7 @@ the necessary certificates and serve locally over http. kubectl proxy -p 8001 ``` -Then, you can access urls like ```http://127.0.0.1:8001/api/v1/proxy/namespaces/kube-system/services/kube-ui/``` without the need for client certificates in your browser. +Then, you can access urls like ```http://127.0.0.1:8001/api/v1/namespaces/kube-system/services/kube-ui/proxy/``` without the need for client certificates in your browser. ## What Kubernetes features do not work on CenturyLink Cloud diff --git a/docs/getting-started-guides/ubuntu/installation.md b/docs/getting-started-guides/ubuntu/installation.md index 9e3bdd8b2b..4322a0ef12 100644 --- a/docs/getting-started-guides/ubuntu/installation.md +++ b/docs/getting-started-guides/ubuntu/installation.md @@ -175,10 +175,10 @@ Output: ``` Kubernetes master is running at https://52.15.104.227:443 -Heapster is running at https://52.15.104.227:443/api/v1/proxy/namespaces/kube-system/services/heapster -KubeDNS is running at https://52.15.104.227:443/api/v1/proxy/namespaces/kube-system/services/kube-dns -Grafana is running at https://52.15.104.227:443/api/v1/proxy/namespaces/kube-system/services/monitoring-grafana -InfluxDB is running at https://52.15.104.227:443/api/v1/proxy/namespaces/kube-system/services/monitoring-influxdb +Heapster is running at https://52.15.104.227:443/api/v1/namespaces/kube-system/services/heapster/proxy +KubeDNS is running at https://52.15.104.227:443/api/v1/namespaces/kube-system/services/kube-dns/proxy +Grafana is running at https://52.15.104.227:443/api/v1/namespaces/kube-system/services/monitoring-grafana/proxy +InfluxDB is running at https://52.15.104.227:443/api/v1/namespaces/kube-system/services/monitoring-influxdb/proxy ``` Congratulations, you've now set up a Kubernetes cluster! diff --git a/docs/user-guide/docker-cli-to-kubectl.md b/docs/user-guide/docker-cli-to-kubectl.md index 0de0d03b7d..b3fcf31a7c 100644 --- a/docs/user-guide/docker-cli-to-kubectl.md +++ b/docs/user-guide/docker-cli-to-kubectl.md @@ -270,9 +270,9 @@ With kubectl: ```shell $ kubectl cluster-info Kubernetes master is running at https://108.59.85.141 -KubeDNS is running at https://108.59.85.141/api/v1/proxy/namespaces/kube-system/services/kube-dns -KubeUI is running at https://108.59.85.141/api/v1/proxy/namespaces/kube-system/services/kube-ui -Grafana is running at https://108.59.85.141/api/v1/proxy/namespaces/kube-system/services/monitoring-grafana -Heapster is running at https://108.59.85.141/api/v1/proxy/namespaces/kube-system/services/monitoring-heapster -InfluxDB is running at https://108.59.85.141/api/v1/proxy/namespaces/kube-system/services/monitoring-influxdb +KubeDNS is running at https://108.59.85.141/api/v1/namespaces/kube-system/services/kube-dns/proxy +KubeUI is running at https://108.59.85.141/api/v1/namespaces/kube-system/services/kube-ui/proxy +Grafana is running at https://108.59.85.141/api/v1/namespaces/kube-system/services/monitoring-grafana/proxy +Heapster is running at https://108.59.85.141/api/v1/namespaces/kube-system/services/monitoring-heapster/proxy +InfluxDB is running at https://108.59.85.141/api/v1/namespaces/kube-system/services/monitoring-influxdb/proxy ``` diff --git a/docs/user-guide/update-demo/local/script.js b/docs/user-guide/update-demo/local/script.js index d6edb74f73..c339c77d27 100644 --- a/docs/user-guide/update-demo/local/script.js +++ b/docs/user-guide/update-demo/local/script.js @@ -17,7 +17,7 @@ limitations under the License. var base = "/api/v1/"; var updateImage = function($http, server) { - $http.get(base + "proxy/namespaces/default/pods/" + server.podName + "/data.json") + $http.get(base + "namespaces/default/pods/" + server.podName + "/proxy/data.json") .success(function(data) { console.log(data); server.image = data.image;