From cb18a8519ec6ee2dfa3a8bf0e04471221e25b9df Mon Sep 17 00:00:00 2001
From: Stewart-YU
Date: Sat, 19 Aug 2017 10:00:31 +0800
Subject: [PATCH 01/14] Update kubectl-overview.md
Fix the format. The format in orginal web page is confusion.
---
docs/user-guide/kubectl-overview.md | 2 ++
1 file changed, 2 insertions(+)
diff --git a/docs/user-guide/kubectl-overview.md b/docs/user-guide/kubectl-overview.md
index ba735d7fee..5170ed7150 100644
--- a/docs/user-guide/kubectl-overview.md
+++ b/docs/user-guide/kubectl-overview.md
@@ -16,7 +16,9 @@ kubectl [command] [TYPE] [NAME] [flags]
```
where `command`, `TYPE`, `NAME`, and `flags` are:
+
* `command`: Specifies the operation that you want to perform on one or more resources, for example `create`, `get`, `describe`, `delete`.
+
* `TYPE`: Specifies the [resource type](#resource-types). Resource types are case-sensitive and you can specify the singular, plural, or abbreviated forms. For example, the following commands produce the same output:
$ kubectl get pod pod1
From edb999f22785f5d5d4a932aad9a88d9e4486cc88 Mon Sep 17 00:00:00 2001
From: XsWack
Date: Sat, 19 Aug 2017 11:24:21 +0800
Subject: [PATCH 02/14] Update determine-reason-pod-failure.md
format the command line
---
.../debug-application-cluster/determine-reason-pod-failure.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/tasks/debug-application-cluster/determine-reason-pod-failure.md b/docs/tasks/debug-application-cluster/determine-reason-pod-failure.md
index 4b300c32dd..74dff233ef 100644
--- a/docs/tasks/debug-application-cluster/determine-reason-pod-failure.md
+++ b/docs/tasks/debug-application-cluster/determine-reason-pod-failure.md
@@ -72,7 +72,7 @@ the container starts.
only the termination message:
```
-{% raw %} kubectl get pod termination-demo -o go-template="{{range .status.containerStatuses}}{{.lastState.terminated.message}}{{end}}"{% endraw %}
+{% raw %} kubectl get pod termination-demo -o go-template="{{range .status.containerStatuses}}{{.lastState.terminated.message}}{{end}}"{% endraw %}
```
## Setting the termination log file
From 221383088e1a73895d9a1ccf9422ffdb9c1eb4ba Mon Sep 17 00:00:00 2001
From: Stewart-YU
Date: Mon, 21 Aug 2017 08:16:34 +0800
Subject: [PATCH 03/14] Update page-templates.md
Fix the size of Font.
---
docs/home/contribute/page-templates.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/docs/home/contribute/page-templates.md b/docs/home/contribute/page-templates.md
index 726969d2a4..060bd25a56 100644
--- a/docs/home/contribute/page-templates.md
+++ b/docs/home/contribute/page-templates.md
@@ -33,7 +33,7 @@ variables:
whatsnext - optional
-Then include templates/task.md like this:
+Then include templates/task.md like this:
{% raw %}...
{% include templates/task.md %}{% endraw %}
@@ -105,7 +105,7 @@ variables:
whatsnext - optional
-Then include templates/tutorial.md like this:
+Then include templates/tutorial.md like this:
{% raw %}...
{% include templates/tutorial.md %}{% endraw %}
@@ -185,7 +185,7 @@ variables:
whatsnext - optional
-Then include templates/concept.md like this:
+Then include templates/concept.md like this:
{% raw %}...
{% include templates/concept.md %}{% endraw %}
From 33ae774e3f57ecc209f648412cbf8e6a1cb2ab86 Mon Sep 17 00:00:00 2001
From: Stewart-YU
Date: Tue, 22 Aug 2017 08:31:29 +0800
Subject: [PATCH 04/14] Update volumes.md (#5026)
* Update volumes.md
Fix leading spaces in commands. And fix command line format.
* change bullet points into tabs
* tidy
---
docs/concepts/storage/volumes.md | 19 ++++++++++++++-----
1 file changed, 14 insertions(+), 5 deletions(-)
diff --git a/docs/concepts/storage/volumes.md b/docs/concepts/storage/volumes.md
index 2d2f4f710f..b9a9368d83 100644
--- a/docs/concepts/storage/volumes.md
+++ b/docs/concepts/storage/volumes.md
@@ -581,18 +581,27 @@ __Important: You must create VMDK using one of the following method before using
#### Creating a VMDK volume
-* Create using vmkfstools.
+Choose one of the following methods to create a VMDK.
- First ssh into ESX and then use following command to create vmdk,
+{% capture vmkfstools %}
+First ssh into ESX, then use the following command to create a VMDK:
```shell
- vmkfstools -c 2G /vmfs/volumes/DatastoreName/volumes/myDisk.vmdk
+vmkfstools -c 2G /vmfs/volumes/DatastoreName/volumes/myDisk.vmdk
```
+{% endcapture %}
+
+{% capture vdiskmanager %}
+Use the following command to create a VMDK:
-* Create using vmware-vdiskmanager.
```shell
- vmware-vdiskmanager -c -t 0 -s 40GB -a lsilogic myDisk.vmdk
+vmware-vdiskmanager -c -t 0 -s 40GB -a lsilogic myDisk.vmdk
```
+{% endcapture %}
+
+{% assign tab_names = 'Create using vmkfstools,Create using vmware-vdiskmanager' | split: ',' | compact %}
+{% assign tab_contents = site.emptyArray | push: vmkfstools | push: vdiskmanager %}
+{% include tabs.md %}
#### vSphere VMDK Example configuration
From 120960b9540c7d59c071be66477a2ccc5004973b Mon Sep 17 00:00:00 2001
From: irfanurrehman
Date: Tue, 22 Aug 2017 06:22:50 +0530
Subject: [PATCH 05/14] Make kubefed docs similar to rest of the docs in
docs/admin (#4934)
* Change update-imported.docs.sh for kubefed docs
* Stop skipping title check for kubefed docs
* Update kubefed docs with titles
---
docs/admin/kubefed.md | 4 ++++
docs/admin/kubefed_init.md | 4 ++++
docs/admin/kubefed_join.md | 4 ++++
docs/admin/kubefed_options.md | 4 ++++
docs/admin/kubefed_unjoin.md | 4 ++++
docs/admin/kubefed_version.md | 4 ++++
skip_title_check.txt | 6 ------
update-imported-docs.sh | 3 ++-
8 files changed, 26 insertions(+), 7 deletions(-)
diff --git a/docs/admin/kubefed.md b/docs/admin/kubefed.md
index a733eac59e..5d670e438e 100644
--- a/docs/admin/kubefed.md
+++ b/docs/admin/kubefed.md
@@ -1,3 +1,7 @@
+---
+title: kubefed
+notitle: true
+---
## kubefed
kubefed controls a Kubernetes Cluster Federation
diff --git a/docs/admin/kubefed_init.md b/docs/admin/kubefed_init.md
index 656cdde6ee..056fd1025c 100644
--- a/docs/admin/kubefed_init.md
+++ b/docs/admin/kubefed_init.md
@@ -1,3 +1,7 @@
+---
+title: kubefed init
+notitle: true
+---
## kubefed init
Initialize a federation control plane
diff --git a/docs/admin/kubefed_join.md b/docs/admin/kubefed_join.md
index 1f57e75af4..22fafdfedd 100644
--- a/docs/admin/kubefed_join.md
+++ b/docs/admin/kubefed_join.md
@@ -1,3 +1,7 @@
+---
+title: kubefed join
+notitle: true
+---
## kubefed join
Join a cluster to a federation
diff --git a/docs/admin/kubefed_options.md b/docs/admin/kubefed_options.md
index 9784b3226f..54e26b3977 100644
--- a/docs/admin/kubefed_options.md
+++ b/docs/admin/kubefed_options.md
@@ -1,3 +1,7 @@
+---
+title: kubefed options
+notitle: true
+---
## kubefed options
Print the list of flags inherited by all commands
diff --git a/docs/admin/kubefed_unjoin.md b/docs/admin/kubefed_unjoin.md
index db2cec33d2..0eae42292e 100644
--- a/docs/admin/kubefed_unjoin.md
+++ b/docs/admin/kubefed_unjoin.md
@@ -1,3 +1,7 @@
+---
+title: kubefed unjoin
+notitle: true
+---
## kubefed unjoin
Unjoin a cluster from a federation
diff --git a/docs/admin/kubefed_version.md b/docs/admin/kubefed_version.md
index 1bcdf5e417..0e8c194db4 100644
--- a/docs/admin/kubefed_version.md
+++ b/docs/admin/kubefed_version.md
@@ -1,3 +1,7 @@
+---
+title: kubefed version
+notitle: true
+---
## kubefed version
Print the client and server version information
diff --git a/skip_title_check.txt b/skip_title_check.txt
index 915ce048a2..29d3195ed9 100644
--- a/skip_title_check.txt
+++ b/skip_title_check.txt
@@ -4,12 +4,6 @@ docs/getting-started-guides/docker.md
docs/getting-started-guides/docker-multinode.md
docs/user-guide/configmap/README.md
docs/user-guide/downward-api/README.md
-docs/admin/kubefed_unjoin.md
-docs/admin/kubefed_init.md
-docs/admin/kubefed.md
-docs/admin/kubefed_join.md
-docs/admin/kubefed_options.md
-docs/admin/kubefed_version.md
docs/api-reference/extensions/v1beta1/definitions.md
docs/api-reference/extensions/v1beta1/operations.md
docs/api-reference/v1/definitions.md
diff --git a/update-imported-docs.sh b/update-imported-docs.sh
index cc52baeb89..717bb90ffc 100755
--- a/update-imported-docs.sh
+++ b/update-imported-docs.sh
@@ -136,7 +136,7 @@ done <_data/overrides.yml
)
-BINARIES="federation-apiserver.md federation-controller-manager.md kube-apiserver.md kube-controller-manager.md kube-proxy.md kube-scheduler.md kubelet.md"
+BINARIES="federation-apiserver.md federation-controller-manager.md kube-apiserver.md kube-controller-manager.md kube-proxy.md kube-scheduler.md kubelet.md kubefed.md kubefed_init.md kubefed_join.md kubefed_options.md kubefed_unjoin.md kubefed_version.md"
(
cd docs/admin
@@ -149,6 +149,7 @@ BINARIES="federation-apiserver.md federation-controller-manager.md kube-apiserve
---' "$bin"
done
)
+
mv -- "${APIREFDESDIR}" "${APIREFSRCDIR}"
mv -- "${KUBECTLDESDIR}" "${KUBECTLSRCDIR}"
rm -rf -- "${TMPDIR}" "${K8SREPO}"
From d971806377d4c61731e358485f7c250d51722bce Mon Sep 17 00:00:00 2001
From: Weibin Lin
Date: Sun, 20 Aug 2017 14:49:28 +0800
Subject: [PATCH 06/14] Update authenticate-across-clusters-kubeconfig.md
---
.../authenticate-across-clusters-kubeconfig.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/docs/tasks/access-application-cluster/authenticate-across-clusters-kubeconfig.md b/docs/tasks/access-application-cluster/authenticate-across-clusters-kubeconfig.md
index 217c62ce5f..8e34e96780 100644
--- a/docs/tasks/access-application-cluster/authenticate-across-clusters-kubeconfig.md
+++ b/docs/tasks/access-application-cluster/authenticate-across-clusters-kubeconfig.md
@@ -138,7 +138,7 @@ current-context: federal-context
`current-context` is the nickname or 'key' for the cluster,user,namespace tuple that kubectl
will use by default when loading config from this file. You can override any of the values in kubectl
-from the commandline, by passing `--context=CONTEXT`, `--cluster=CLUSTER`, `--user=USER`, and/or `--namespace=NAMESPACE` respectively.
+from the command line, by passing `--context=CONTEXT`, `--cluster=CLUSTER`, `--user=USER`, and/or `--namespace=NAMESPACE` respectively.
You can change the `current-context` with [`kubectl config use-context`](/docs/user-guide/kubectl/{{page.version}}/#-em-use-context-em-).
#### miscellaneous
@@ -315,7 +315,7 @@ So, tying this all together, a quick start to create your own kubeconfig file:
- Make sure your api-server provides at least one set of credentials (for example, `green-user`) when launched. You will of course have to look at api-server documentation in order to determine the current state-of-the-art in terms of providing authentication details.
## Related discussion
-[http://issue.k8s.io/1755](http://issue.k8s.io/1755)
+[https://github.com/kubernetes/kubernetes/issues/1755](https://github.com/kubernetes/kubernetes/issues/1755)
{% endcapture %}
{% include templates/task.md %}
From 3cc885a3b9307858c5bad1f9f009cca75a7e8a36 Mon Sep 17 00:00:00 2001
From: Weibin Lin
Date: Sat, 19 Aug 2017 10:54:04 +0800
Subject: [PATCH 07/14] Update list-all-running-container-images.md
fixed syntax error
---
.../list-all-running-container-images.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/tasks/access-application-cluster/list-all-running-container-images.md b/docs/tasks/access-application-cluster/list-all-running-container-images.md
index 922e5c62d6..358a93b476 100644
--- a/docs/tasks/access-application-cluster/list-all-running-container-images.md
+++ b/docs/tasks/access-application-cluster/list-all-running-container-images.md
@@ -46,7 +46,7 @@ for all items returned.
As an alternative, it is possible to use the absolute path to the image
field within the Pod. This ensures the correct field is retrieved
-in the even the field name is repeated,
+even when the field name is repeated,
e.g. many fields are called `name` within a given item:
```sh
From 1f5b64b24fad8adc162a74f23028491cb35421ce Mon Sep 17 00:00:00 2001
From: Slava Semushin
Date: Mon, 21 Aug 2017 15:28:28 +0200
Subject: [PATCH 08/14] encrypt-data.md: fix name of the secret in kubectl
command.
---
docs/tasks/administer-cluster/encrypt-data.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/tasks/administer-cluster/encrypt-data.md b/docs/tasks/administer-cluster/encrypt-data.md
index d7644e0f77..171eae0075 100644
--- a/docs/tasks/administer-cluster/encrypt-data.md
+++ b/docs/tasks/administer-cluster/encrypt-data.md
@@ -137,7 +137,7 @@ program to retrieve the contents of your secret.
4. Verify the secret is correctly decrypted when retrieved via the API:
```
- kubectl describe secret generic -n default
+ kubectl describe secret secret1 -n default
```
should match `mykey: mydata`
From d98467f15ff85ac3f6b40f47f21be40f4d0844c9 Mon Sep 17 00:00:00 2001
From: Anthony
Date: Tue, 22 Aug 2017 08:58:45 +0800
Subject: [PATCH 09/14] Update networking.md
modify "ethernet" to "Ethernet"
---
docs/concepts/cluster-administration/networking.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/concepts/cluster-administration/networking.md b/docs/concepts/cluster-administration/networking.md
index 99b2106829..494c7fb3ac 100644
--- a/docs/concepts/cluster-administration/networking.md
+++ b/docs/concepts/cluster-administration/networking.md
@@ -37,7 +37,7 @@ review the "normal" way that networking works with Docker. By default, Docker
uses host-private networking. It creates a virtual bridge, called `docker0` by
default, and allocates a subnet from one of the private address blocks defined
in [RFC1918](https://tools.ietf.org/html/rfc1918) for that bridge. For each
-container that Docker creates, it allocates a virtual ethernet device (called
+container that Docker creates, it allocates a virtual Ethernet device (called
`veth`) which is attached to the bridge. The veth is mapped to appear as `eth0`
in the container, using Linux namespaces. The in-container `eth0` interface is
given an IP address from the bridge's address range.
From f76768cdc28e9110d538bdb0be6a86c041a0cfcf Mon Sep 17 00:00:00 2001
From: Anthony
Date: Tue, 22 Aug 2017 11:34:24 +0800
Subject: [PATCH 10/14] Update logging.md
add ":" to the sentence
---
docs/concepts/cluster-administration/logging.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/concepts/cluster-administration/logging.md b/docs/concepts/cluster-administration/logging.md
index b32c1d05bf..42475f124f 100644
--- a/docs/concepts/cluster-administration/logging.md
+++ b/docs/concepts/cluster-administration/logging.md
@@ -33,7 +33,7 @@ $ kubectl create -f https://k8s.io/docs/tasks/debug-application-cluster/counter-
pod "counter" created
```
-To fetch the logs, use the `kubectl logs` command, as follows
+To fetch the logs, use the `kubectl logs` command, as follows:
```shell
$ kubectl logs counter
From af1a7532c4f0d47f98d914a753fab8e926838cf7 Mon Sep 17 00:00:00 2001
From: Anthony
Date: Tue, 22 Aug 2017 15:46:18 +0800
Subject: [PATCH 11/14] Update resource-quotas.md
modify "Gib" to "GiB"
---
docs/concepts/policy/resource-quotas.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/concepts/policy/resource-quotas.md b/docs/concepts/policy/resource-quotas.md
index 423b0aa40f..e1453e1813 100644
--- a/docs/concepts/policy/resource-quotas.md
+++ b/docs/concepts/policy/resource-quotas.md
@@ -30,7 +30,7 @@ Resource quotas work like this:
Examples of policies that could be created using namespaces and quotas are:
-- In a cluster with a capacity of 32 GiB RAM, and 16 cores, let team A use 20 Gib and 10 cores,
+- In a cluster with a capacity of 32 GiB RAM, and 16 cores, let team A use 20 GiB and 10 cores,
let B use 10GiB and 4 cores, and hold 2GiB and 2 cores in reserve for future allocation.
- Limit the "testing" namespace to using 1 core and 1GiB RAM. Let the "production" namespace
use any amount.
From 8296d727e05952a4a9620f7719f7658a362fe414 Mon Sep 17 00:00:00 2001
From: Anthony
Date: Tue, 22 Aug 2017 15:51:51 +0800
Subject: [PATCH 12/14] Update pod-security-policy.md
modify "api" to "API" and "boolean" to "Boolean"
---
docs/concepts/policy/pod-security-policy.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/docs/concepts/policy/pod-security-policy.md b/docs/concepts/policy/pod-security-policy.md
index 74f603dff3..658998281e 100644
--- a/docs/concepts/policy/pod-security-policy.md
+++ b/docs/concepts/policy/pod-security-policy.md
@@ -42,7 +42,7 @@ _Pod Security Policies_ are comprised of settings and strategies that
control the security features a pod has access to. These settings fall
into three categories:
-- *Controlled by a boolean*: Fields of this type default to the most
+- *Controlled by a Boolean*: Fields of this type default to the most
restrictive value.
- *Controlled by an allowable set*: Fields of this type are checked
against the set to ensure their values are allowed.
@@ -193,7 +193,7 @@ podsecuritypolicy "permissive" deleted
In order to use Pod Security Policies in your cluster you must ensure the
following
-1. You have enabled the api type `extensions/v1beta1/podsecuritypolicy` (only for versions prior 1.6)
+1. You have enabled the API type `extensions/v1beta1/podsecuritypolicy` (only for versions prior 1.6)
1. You have enabled the admission controller `PodSecurityPolicy`
1. You have defined your policies
From a44edb64b0d84d5e4b300e86e77b3a4093294cb9 Mon Sep 17 00:00:00 2001
From: XsWack
Date: Tue, 22 Aug 2017 21:59:31 +0800
Subject: [PATCH 13/14] Update rollback-daemon-set.md
The output is wrong and it should be "daemonset"
---
docs/tasks/manage-daemon/rollback-daemon-set.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/tasks/manage-daemon/rollback-daemon-set.md b/docs/tasks/manage-daemon/rollback-daemon-set.md
index 1bcef271c4..524d733371 100644
--- a/docs/tasks/manage-daemon/rollback-daemon-set.md
+++ b/docs/tasks/manage-daemon/rollback-daemon-set.md
@@ -99,7 +99,7 @@ kubectl rollout status ds/
When the rollback is complete, the output is similar to this:
```shell
-daemon set "" successfully rolled out
+daemonset "" successfully rolled out
```
{% endcapture %}
From c0e33050ab6d84a12fcc121b1934d3605f33d2d0 Mon Sep 17 00:00:00 2001
From: Ahmet Alp Balkan
Date: Fri, 18 Aug 2017 17:19:11 -0700
Subject: [PATCH 14/14] Stop importing tutorials from k/examples repo
Signed-off-by: Ahmet Alp Balkan
---
.../stateful-application/cassandra.md | 65 ++------
.../{ => cassandra}/cassandra-service.yaml | 0
.../cassandra-statefulset.yaml | 0
.../mysql-wordpress-persistent-volume.md | 63 ++------
.../stateless-application/guestbook.md | 68 ++------
update-imported-tutorials.py | 149 ------------------
6 files changed, 40 insertions(+), 305 deletions(-)
rename docs/tutorials/stateful-application/{ => cassandra}/cassandra-service.yaml (100%)
rename docs/tutorials/stateful-application/{ => cassandra}/cassandra-statefulset.yaml (100%)
delete mode 100755 update-imported-tutorials.py
diff --git a/docs/tutorials/stateful-application/cassandra.md b/docs/tutorials/stateful-application/cassandra.md
index d17d6d9be6..c7d23d0be3 100644
--- a/docs/tutorials/stateful-application/cassandra.md
+++ b/docs/tutorials/stateful-application/cassandra.md
@@ -1,48 +1,13 @@
---
title: "Example: Deploying Cassandra with Stateful Sets"
+assignees:
+- ahmetb
---
-
-
-
{% capture overview %}
This tutorial shows you how to develop a native cloud [Cassandra](http://cassandra.apache.org/) deployment on Kubernetes. In this instance, a custom Cassandra `SeedProvider` enables Cassandra to discover new Cassandra nodes as they join the cluster.
-Deploying stateful distributed applications, like Cassandra, within a clustered environment can be challenging. StatefulSets greatly simplify this process. Please read about [StatefulSets](https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/) for more information about the features used in this tutorial.
+Deploying stateful distributed applications, like Cassandra, within a clustered environment can be challenging. StatefulSets greatly simplify this process. Please read about [StatefulSets](/docs/concepts/workloads/controllers/statefulset/) for more information about the features used in this tutorial.
**Cassandra Docker**
@@ -67,20 +32,20 @@ The docker is based on `debian:jessie` and includes OpenJDK 8. This image includ
{% endcapture %}
{% capture prerequisites %}
-To complete this tutorial, you should already have a basic familiarity with [Pods](https://kubernetes.io/docs/concepts/workloads/pods/pod/), [Services](https://kubernetes.io/docs/concepts/services-networking/service/), and [StatefulSets](https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/). In addition, you should:
+To complete this tutorial, you should already have a basic familiarity with [Pods](/docs/concepts/workloads/pods/pod/), [Services](/docs/concepts/services-networking/service/), and [StatefulSets](/docs/concepts/workloads/controllers/statefulset/). In addition, you should:
-* [Install and Configure](https://kubernetes.io/docs/tasks/tools/install-kubectl/) the `kubectl` command line
+* [Install and Configure](/docs/tasks/tools/install-kubectl/) the `kubectl` command line
-* Download [cassandra-service.yaml](https://kubernetes.io/docs/tutorials/stateful-application/cassandra-service.yaml) and [cassandra-statefulset.yaml](https://kubernetes.io/docs/tutorials/stateful-application/cassandra-statefulset.yaml)
+* Download [cassandra-service.yaml](/docs/tutorials/stateful-application/cassandra/cassandra-service.yaml) and [cassandra-statefulset.yaml](/docs/tutorials/stateful-application/cassandra/cassandra-statefulset.yaml)
* Have a supported Kubernetes Cluster running
-**Note:** Please read the [getting started guides](https://kubernetes.io/docs/setup/pick-right-solution/) if you do not already have a cluster.
+**Note:** Please read the [getting started guides](/docs/setup/pick-right-solution/) if you do not already have a cluster.
{: .note}
### Additional Minikube Setup Instructions
-**Caution:** [Minikube](https://kubernetes.io/docs/getting-started-guides/minikube/) defaults to 1024MB of memory and 1 CPU which results in an insufficient resource errors during this tutorial.
+**Caution:** [Minikube](/docs/getting-started-guides/minikube/) defaults to 1024MB of memory and 1 CPU which results in an insufficient resource errors during this tutorial.
{: .caution}
To avoid these errors, run minikube with:
@@ -91,7 +56,7 @@ To avoid these errors, run minikube with:
{% capture lessoncontent %}
## Creating a Cassandra Headless Service
-A Kubernetes [Service](https://kubernetes.io/docs/concepts/services-networking/service/) describes a set of [Pods](https://kubernetes.io/docs/concepts/workloads/pods/pod/) that perform the same task.
+A Kubernetes [Service](/docs/concepts/services-networking/service/) describes a set of [Pods](/docs/concepts/workloads/pods/pod/) that perform the same task.
The following `Service` is used for DNS lookups between Cassandra Pods and clients within the Kubernetes Cluster.
@@ -100,7 +65,7 @@ The following `Service` is used for DNS lookups between Cassandra Pods and clien
kubectl create -f cassandra-service.yaml
-{% include code.html language="yaml" file="cassandra-service.yaml" ghlink="/docs/tutorials/stateful-application/cassandra-service.yaml" %}
+{% include code.html language="yaml" file="cassandra/cassandra-service.yaml" ghlink="/docs/tutorials/stateful-application/cassandra/cassandra-service.yaml" %}
### Validating (optional)
@@ -113,7 +78,7 @@ The response should be
NAME CLUSTER-IP EXTERNAL-IP PORT(S) AGE
cassandra None 9042/TCP 45s
-If anything else returns, the service was not successfully created. Read [Debug Services](https://kubernetes.io/docs/tasks/debug-application-cluster/debug-service/) for common issues.
+If anything else returns, the service was not successfully created. Read [Debug Services](/docs/tasks/debug-application-cluster/debug-service/) for common issues.
## Using a StatefulSet to Create a Cassandra Ring
@@ -127,7 +92,7 @@ The StatefulSet manifest, included below, creates a Cassandra ring that consists
kubectl create -f cassandra-statefulset.yaml
-{% include code.html language="yaml" file="cassandra-statefulset.yaml" ghlink="/docs/tutorials/stateful-application/cassandra-statefulset.yaml" %}
+{% include code.html language="yaml" file="cassandra/cassandra-statefulset.yaml" ghlink="/docs/tutorials/stateful-application/cassandra/cassandra-statefulset.yaml" %}
## Validating The Cassandra StatefulSet
@@ -246,14 +211,10 @@ Deleting or scaling a StatefulSet down does not delete the volumes associated wi
{% endcapture %}
{% capture whatsnext %}
-* Learn how to [Scale a StatefulSet](https://kubernetes.io/docs/tasks/run-application/scale-stateful-set/).
+* Learn how to [Scale a StatefulSet](/docs/tasks/run-application/scale-stateful-set/).
* Learn more about the [KubernetesSeedProvider](https://github.com/kubernetes/examples/blob/master/cassandra/java/src/main/java/io/k8s/cassandra/KubernetesSeedProvider.java)
* See more custom [Seed Provider Configurations](https://git.k8s.io/examples/cassandra/java/README.md)
{% endcapture %}
{% include templates/tutorial.md %}
-
-
-[]()
-
\ No newline at end of file
diff --git a/docs/tutorials/stateful-application/cassandra-service.yaml b/docs/tutorials/stateful-application/cassandra/cassandra-service.yaml
similarity index 100%
rename from docs/tutorials/stateful-application/cassandra-service.yaml
rename to docs/tutorials/stateful-application/cassandra/cassandra-service.yaml
diff --git a/docs/tutorials/stateful-application/cassandra-statefulset.yaml b/docs/tutorials/stateful-application/cassandra/cassandra-statefulset.yaml
similarity index 100%
rename from docs/tutorials/stateful-application/cassandra-statefulset.yaml
rename to docs/tutorials/stateful-application/cassandra/cassandra-statefulset.yaml
diff --git a/docs/tutorials/stateful-application/mysql-wordpress-persistent-volume.md b/docs/tutorials/stateful-application/mysql-wordpress-persistent-volume.md
index 22cb8bd142..3dab51db28 100644
--- a/docs/tutorials/stateful-application/mysql-wordpress-persistent-volume.md
+++ b/docs/tutorials/stateful-application/mysql-wordpress-persistent-volume.md
@@ -1,48 +1,13 @@
---
title: "Example: Deploying WordPress and MySQL with Persistent Volumes"
+assignees:
+- ahmetb
---
-
-
-
{% capture overview %}
This tutorial shows you how to deploy a WordPress site and a MySQL database using Minikube. Both applications use PersistentVolumes and PersistentVolumeClaims to store data.
-A [PersistentVolume](https://kubernetes.io/docs/concepts/storage/persistent-volumes/) (PV) is a piece of storage in the cluster that has been provisioned by an administrator, and a [PeristentVolumeClaim](https://kubernetes.io/docs/concepts/storage/persistent-volumes/#persistentvolumeclaims) (PVC) is a set amout of storage in a PV. PersistentVolumes and PeristentVolumeClaims are independent from Pod lifecycles and preserve data through restarting, rescheduling, and even deleting Pods.
+A [PersistentVolume](/docs/concepts/storage/persistent-volumes/) (PV) is a piece of storage in the cluster that has been provisioned by an administrator, and a [PeristentVolumeClaim](/docs/concepts/storage/persistent-volumes/#persistentvolumeclaims) (PVC) is a set amout of storage in a PV. PersistentVolumes and PeristentVolumeClaims are independent from Pod lifecycles and preserve data through restarting, rescheduling, and even deleting Pods.
**Warning:** This deployment is not suitable for production use cases, as it uses single instance WordPress and MySQL Pods. Consider using [WordPress Helm Chart](https://github.com/kubernetes/charts/tree/master/stable/wordpress) to deploy WordPress in production.
{: .warning}
@@ -64,11 +29,11 @@ A [PersistentVolume](https://kubernetes.io/docs/concepts/storage/persistent-volu
Download the following configuration files:
-1. [local-volumes.yaml](https://kubernetes.io/docs/tutorials/stateful-application/mysql-wordpress-persistent-volume/local-volumes.yaml)
+1. [local-volumes.yaml](/docs/tutorials/stateful-application/mysql-wordpress-persistent-volume/local-volumes.yaml)
-1. [mysql-deployment.yaml](https://kubernetes.io/docs/tutorials/stateful-application/mysql-wordpress-persistent-volume/mysql-deployment.yaml)
+1. [mysql-deployment.yaml](/docs/tutorials/stateful-application/mysql-wordpress-persistent-volume/mysql-deployment.yaml)
-1. [wordpress-deployment.yaml](https://kubernetes.io/docs/tutorials/stateful-application/mysql-wordpress-persistent-volume//wordpress-deployment.yaml)
+1. [wordpress-deployment.yaml](/docs/tutorials/stateful-application/mysql-wordpress-persistent-volume/wordpress-deployment.yaml)
{% endcapture %}
@@ -76,7 +41,7 @@ Download the following configuration files:
## Create a PersistentVolume
-MySQL and Wordpress each use a PersistentVolume to store data. While Kubernetes supports many different [types of PersistentVolumes](https://kubernetes.io/docs/concepts/storage/persistent-volumes/#types-of-persistent-volumes), this tutorial covers [hostPath](https://kubernetes.io/docs/concepts/storage/volumes/#hostpath).
+MySQL and Wordpress each use a PersistentVolume to store data. While Kubernetes supports many different [types of PersistentVolumes](/docs/concepts/storage/persistent-volumes/#types-of-persistent-volumes), this tutorial covers [hostPath](/docs/concepts/storage/volumes/#hostpath).
**Note:** If you have a Kubernetes cluster running on Google Container Engine, please follow [this guide](https://cloud.google.com/container-engine/docs/tutorials/persistent-disk).
{: .note}
@@ -109,7 +74,7 @@ A `hostPath` mounts a file or directory from the host node’s filesystem into y
## Create a Secret for MySQL Password
-A [Secret](https://kubernetes.io/docs/concepts/configuration/secret/) is an object that stores a piece of sensitive data like a password or key. The manifest files are already configured to use a Secret, but you have to create your own Secret.
+A [Secret](/docs/concepts/configuration/secret/) is an object that stores a piece of sensitive data like a password or key. The manifest files are already configured to use a Secret, but you have to create your own Secret.
1. Create the Secret object from the following command:
@@ -216,15 +181,11 @@ The following manifest describes a single-instance WordPress Deployment and Serv
{% capture whatsnext %}
-* Learn more about [Introspection and Debugging](https://kubernetes.io/docs/tasks/debug-application-cluster/debug-application-introspection/)
-* Learn more about [Jobs](https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/)
-* Learn more about [Port Forwarding](https://kubernetes.io/docs/tasks/access-application-cluster/port-forward-access-application-cluster/)
-* Learn how to [Get a Shell to a Container](https://kubernetes.io/docs/tasks/debug-application-cluster/get-shell-running-container/)
+* Learn more about [Introspection and Debugging](/docs/tasks/debug-application-cluster/debug-application-introspection/)
+* Learn more about [Jobs](/docs/concepts/workloads/controllers/jobs-run-to-completion/)
+* Learn more about [Port Forwarding](/docs/tasks/access-application-cluster/port-forward-access-application-cluster/)
+* Learn how to [Get a Shell to a Container](/docs/tasks/debug-application-cluster/get-shell-running-container/)
{% endcapture %}
{% include templates/tutorial.md %}
-
-
-[]()
-
\ No newline at end of file
diff --git a/docs/tutorials/stateless-application/guestbook.md b/docs/tutorials/stateless-application/guestbook.md
index ca47e5d16e..ec394ecb72 100644
--- a/docs/tutorials/stateless-application/guestbook.md
+++ b/docs/tutorials/stateless-application/guestbook.md
@@ -1,44 +1,9 @@
---
title: "Example: Deploying PHP Guestbook application with Redis"
+assignees:
+- ahmetb
---
-
-
-
{% capture overview %}
This tutorial shows you how to build and deploy a simple, multi-tier web application using Kubernetes and [Docker](https://www.docker.com/). This example consists of the following components:
@@ -61,12 +26,12 @@ This tutorial shows you how to build and deploy a simple, multi-tier web applica
{% include task-tutorial-prereqs.md %}
Download the following configuration files:
-1. [redis-master-deployment.yaml](https://kubernetes.io/docs/tutorials/stateless-application/guestbook/redis-master-deployment.yaml)
-1. [redis-master-service.yaml](https://kubernetes.io/docs/tutorials/stateless-application/guestbook/redis-master-service.yaml)
-1. [redis-slave-deployment.yaml](https://kubernetes.io/docs/tutorials/stateless-application/guestbook/redis-slave-deployment.yaml)
-1. [redis-slave-service.yaml](https://kubernetes.io/docs/tutorials/stateless-application/guestbook/redis-slave-service.yaml)
-1. [frontend-deployment.yaml](https://kubernetes.io/docs/tutorials/stateless-application/guestbook/frontend-deployment.yaml)
-1. [frontend-service.yaml](https://kubernetes.io/docs/tutorials/stateless-application/guestbook/frontend-service.yaml)
+1. [redis-master-deployment.yaml](/docs/tutorials/stateless-application/guestbook/redis-master-deployment.yaml)
+1. [redis-master-service.yaml](/docs/tutorials/stateless-application/guestbook/redis-master-service.yaml)
+1. [redis-slave-deployment.yaml](/docs/tutorials/stateless-application/guestbook/redis-slave-deployment.yaml)
+1. [redis-slave-service.yaml](/docs/tutorials/stateless-application/guestbook/redis-slave-service.yaml)
+1. [frontend-deployment.yaml](/docs/tutorials/stateless-application/guestbook/frontend-deployment.yaml)
+1. [frontend-service.yaml](/docs/tutorials/stateless-application/guestbook/frontend-service.yaml)
{% endcapture %}
@@ -105,7 +70,7 @@ The manifest file, included below, specifies a Deployment controller that runs a
### Creating the Redis Master Service
-The guestbook applications needs to communicate to the Redis master to write its data. You need to apply a [Service](https://kubernetes.io/docs/concepts/services-networking/service/) to proxy the traffic to the Redis master Pod. A Service defines a policy to access the Pods.
+The guestbook applications needs to communicate to the Redis master to write its data. You need to apply a [Service](/docs/concepts/services-networking/service/) to proxy the traffic to the Redis master Pod. A Service defines a policy to access the Pods.
1. Apply the Redis Master Service from the following `redis-master-service.yaml` file:
@@ -199,7 +164,7 @@ The guestbook application has a web frontend serving the HTTP requests written i
### Creating the Frontend Service
-The `redis-slave` and `redis-master` Services you applied are only accessible within the container cluster because the default type for a Service is [ClusterIP](https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services---service-types). `ClusterIP` provides a single IP address for the set of Pods the Service is pointing to. This IP address is accessible only within the cluster.
+The `redis-slave` and `redis-master` Services you applied are only accessible within the container cluster because the default type for a Service is [ClusterIP](/docs/concepts/services-networking/service/#publishing-services---service-types). `ClusterIP` provides a single IP address for the set of Pods the Service is pointing to. This IP address is accessible only within the cluster.
If you want guests to be able to access your guestbook, you must configure the frontend Service to be externally visible, so a client can request the Service from outside the container cluster. Minikube can only expose Services through `NodePort`.
@@ -326,13 +291,10 @@ Deleting the Deployments and Services also deletes any running Pods. Use labels
{% endcapture %}
{% capture whatsnext %}
-* Complete the [Kubernetes Basics](https://kubernetes.io//docs/tutorials/kubernetes-basics/) Interactive Tutorials
-* Use Kubernetes to create a blog using [Persistant Volumes for MySQL and Wordpress](https://kubernetes.io/docs/tutorials/stateful-application/mysql-wordpress-persistent-volume/#visit-your-new-wordpress-blog)
-* Read more about [connecting applications](https://kubernetes.io/docs/concepts/services-networking/connect-applications-service/)
-* Read more about [Managing Resources](https://kubernetes.io/docs/concepts/cluster-administration/manage-deployment/#using-labels-effectively)
+* Complete the [Kubernetes Basics](/docs/tutorials/kubernetes-basics/) Interactive Tutorials
+* Use Kubernetes to create a blog using [Persistant Volumes for MySQL and Wordpress](/docs/tutorials/stateful-application/mysql-wordpress-persistent-volume/#visit-your-new-wordpress-blog)
+* Read more about [connecting applications](/docs/concepts/services-networking/connect-applications-service/)
+* Read more about [Managing Resources](/docs/concepts/cluster-administration/manage-deployment/#using-labels-effectively)
{% endcapture %}
-{% include templates/tutorial.md %}
-
-[]()
-
+{% include templates/tutorial.md %}
diff --git a/update-imported-tutorials.py b/update-imported-tutorials.py
deleted file mode 100755
index 81b14181f6..0000000000
--- a/update-imported-tutorials.py
+++ /dev/null
@@ -1,149 +0,0 @@
-#!/usr/bin/env python3
-# -*- coding: utf-8 -*-
-
-# Copyright 2017 The Kubernetes Authors.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-"""This program imports the tutorials from
-https://github.com/kubernetes/examples and makes necessary modifications to
-check them in as Jekyll-compatible documentation pages.
-"""
-
-import os.path
-import shutil
-import urllib.request
-
-SRC_REPO = 'kubernetes/examples'
-SRC_TREE = 'master'
-
-# mapping of tutorials in kubernetes/examples to their
-# equivalent files here: (examples-path, docs-path, new-title, imports-map)
-TUTORIALS = [
- ('guestbook/README.md',
- './docs/tutorials/stateless-application/guestbook.md',
- "Example: Deploying PHP Guestbook application with Redis", {
- "guestbook/redis-master-deployment.yaml" : "./docs/tutorials/stateless-application/guestbook/redis-master-deployment.yaml",
- "guestbook/redis-master-service.yaml" : "./docs/tutorials/stateless-application/guestbook/redis-master-service.yaml",
- "guestbook/redis-slave-deployment.yaml" : "./docs/tutorials/stateless-application/guestbook/redis-slave-deployment.yaml",
- "guestbook/redis-slave-service.yaml" : "./docs/tutorials/stateless-application/guestbook/redis-slave-service.yaml",
- "guestbook/frontend-deployment.yaml" : "./docs/tutorials/stateless-application/guestbook/frontend-deployment.yaml",
- "guestbook/frontend-service.yaml" : "./docs/tutorials/stateless-application/guestbook/frontend-service.yaml",
- }),
- ('mysql-wordpress-pd/README.md',
- './docs/tutorials/stateful-application/mysql-wordpress-persistent-volume.md',
- "Example: Deploying WordPress and MySQL with Persistent Volumes",
- {
- "mysql-wordpress-pd/local-volumes.yaml": "./docs/tutorials/stateful-application/mysql-wordpress-persistent-volume/local-volumes.yaml",
- "mysql-wordpress-pd/mysql-deployment.yaml": "./docs/tutorials/stateful-application/mysql-wordpress-persistent-volume/mysql-deployment.yaml",
- "mysql-wordpress-pd/wordpress-deployment.yaml": "./docs/tutorials/stateful-application/mysql-wordpress-persistent-volume/wordpress-deployment.yaml",
- }),
- ('cassandra/README.md',
- './docs/tutorials/stateful-application/cassandra.md',
- "Example: Deploying Cassandra with Stateful Sets",
- {
- "cassandra/cassandra-service.yaml": "./docs/tutorials/stateful-application/cassandra-service.yaml",
- "cassandra/cassandra-statefulset.yaml": "./docs/tutorials/stateful-application/cassandra-statefulset.yaml",
- }),
-]
-
-
-def main():
- for (src_path, dst_path, new_title, imports) in TUTORIALS:
- print('Processing {0}'.format(src_path))
-
- imports[src_path] = dst_path # add source itself as import file
- for src_path, dst_path in imports.items():
- src_url = 'https://github.com/{0}/raw/{1}/{2}'.format(SRC_REPO,
- SRC_TREE, src_path)
- dst_dir = os.path.dirname(dst_path)
- if not os.path.exists(dst_dir):
- print('Creating directory {0}.'.format(dst_dir))
- os.makedirs(dst_dir)
-
- print('Downloading {0}'.format(src_url))
- with urllib.request.urlopen(src_url) as resp, \
- open(dst_path, 'wb') as out_file:
- shutil.copyfileobj(resp, out_file)
- print('Saved to {0}'.format(dst_path))
-
- print('Processing {0}'.format(dst_path))
- remove_excluded_snippets(dst_path)
- insert_do_not_update(dst_path)
- insert_title(dst_path, new_title)
- print('Processed {0}'.format(dst_path))
-
-
-def remove_excluded_snippets(path):
- """Remove content between '' and
- '' markers (including the markers)
- in the specified file. Markers must appear on their own lines."""
-
- marker_begin = '\n'
- marker_end = '\n'
-
- new_lines = []
- started = False
- excluded_blocks = 0
- with open(path, 'r') as f:
- for line_no, line in enumerate(f):
- ref = '{0}:{1}'.format(path, line_no)
- if (marker_begin.rstrip('\n') in line and
- (line != marker_begin and line != marker_end.rstrip('\n'))) or \
- (marker_end.rstrip('\n') in line and (line != marker_end and
- line != marker_end.rstrip('\n'))):
- raise Exception('{0}: EXCLUDE_FROM_DOCS marker must be on its own line'.format(ref))
- if not started:
- if line == marker_end:
- raise Exception('{0}: encountered END before BEGIN'.format(ref))
- elif line == marker_begin:
- started = True
- else:
- new_lines.append(line.rstrip('\n'))
- else:
- if line == marker_begin:
- raise Exception('{0}: encountered BEGIN again before END'.format(ref))
- elif line == marker_end:
- started = False
- excluded_blocks += 1
- else:
- continue
- if started:
- raise Exception('encountered EOF before END')
- print('{0} EXCLUDE_FROM_DOCS blocks removed.'.format(excluded_blocks))
- with open(path, 'w') as f:
- f.write('\n'.join(new_lines))
-
-
-def insert_title(path, title):
- """Inserts title in Jekyll metadata format to the file."""
- prepend_file(path, '---\ntitle: "{0}"\n---\n\n'.format(title))
-
-
-def insert_do_not_update(path):
- notice = '\n\n'
- prepend_file(path, notice)
-
-
-def prepend_file(path, ss):
- with open(path, 'r') as f:
- for line in f:
- ss += line
- with open(path, 'w') as f:
- f.write(ss)
-
-if __name__ == '__main__':
- main()