Skip to content

Commit 09b3563

Browse files
authored
Starting again to fix the issues (#2625)
- edit all lab files - All files + replace passive voice with active + replace contractions with words + replace we with you
1 parent d8f116a commit 09b3563

14 files changed

+103
-111
lines changed

docs/labs/kubernetes-the-hard-way/lab0-README.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,10 @@ author: Wale Soyinka
44
contributors: Steven Spencer
55
---
66

7-
This is a fork of the original ["Kubernetes the hard way"](https://github.com/kelseyhightower/kubernetes-the-hard-way) originally written by Kelsey Hightower (GitHub: kelseyhightower).
8-
Unlike the original that bases itself on Debian like distributions for the ARM64 architecture, this fork targets Enterprise Linux distributions such as Rocky Linux running on x86_64 architecture.
9-
107
# Kubernetes The Hard Way (Rocky Linux)
118

9+
> This is a fork of the original ["Kubernetes the hard way"](https://github.com/kelseyhightower/kubernetes-the-hard-way) originally written by Kelsey Hightower (GitHub: kelseyhightower). Unlike the original that bases itself on Debian like distributions for the ARM64 architecture, this fork targets Enterprise Linux distributions such as Rocky Linux running on x86_64 architecture.
10+
1211
This tutorial walks you through setting up Kubernetes the hard way. This guide is not for someone looking for a fully automated tool to bring up a Kubernetes cluster. Kubernetes The Hard Way, designed for learning, means taking the long route to ensure you understand each task required to bootstrap a Kubernetes cluster.
1312

1413
Do not view the results of this tutorial as production ready, and it might not receive support from the community, but do not let that stop you from learning!

docs/labs/kubernetes-the-hard-way/lab1-prerequisites.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,10 @@ tags:
77
- lab exercise
88
---
99

10-
This is a fork of the original ["Kubernetes the hard way"](https://github.com/kelseyhightower/kubernetes-the-hard-way) originally written by Kelsey Hightower (GitHub: kelseyhightower).
11-
Unlike the original that bases itself on Debian like distributions for the ARM64 architecture, this fork targets Enterprise Linux distributions such as Rocky Linux running on x86_64 architecture.
12-
1310
# Lab 1: Prerequisites
1411

12+
> This is a fork of the original ["Kubernetes the hard way"](https://github.com/kelseyhightower/kubernetes-the-hard-way) originally written by Kelsey Hightower (GitHub: kelseyhightower). Unlike the original that bases itself on Debian like distributions for the ARM64 architecture, this fork targets Enterprise Linux distributions such as Rocky Linux running on x86_64 architecture.
13+
1514
In this lab you will review the machine requirements necessary to follow this tutorial.
1615

1716
## Virtual or Physical Machines

docs/labs/kubernetes-the-hard-way/lab10-configuring-kubectl.md

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,9 @@ tags:
1111
- kubectl
1212
---
1313

14-
This is a fork of the original ["Kubernetes the hard way"](https://github.com/kelseyhightower/kubernetes-the-hard-way) originally written by Kelsey Hightower (GitHub: kelseyhightower).
15-
Unlike the original that bases itself on Debian like distributions for the ARM64 architecture, this fork targets Enterprise Linux distributions such as Rocky Linux running on x86_64 architecture.
14+
# Lab 10: Configuring `kubectl` for Remote Access
1615

17-
18-
# Lab 10: Configuring kubectl for Remote Access
16+
> This is a fork of the original ["Kubernetes the hard way"](https://github.com/kelseyhightower/kubernetes-the-hard-way) originally written by Kelsey Hightower (GitHub: kelseyhightower). Unlike the original that bases itself on Debian like distributions for the ARM64 architecture, this fork targets Enterprise Linux distributions such as Rocky Linux running on x86_64 architecture.
1917
2018
In this lab you will generate a kubeconfig file for the `kubectl` command line utility based on the `admin` user credentials.
2119

@@ -25,7 +23,7 @@ In this lab you will generate a kubeconfig file for the `kubectl` command line u
2523

2624
Each kubeconfig requires a Kubernetes API Server to connect to.
2725

28-
You should be able to ping `server.kubernetes.local` based on the `/etc/hosts` DNS entry from a previous lap.
26+
You should be able to ping `server.kubernetes.local` based on the `/etc/hosts` DNS entry from an earlier lab.
2927

3028
```bash
3129
curl -k --cacert ca.crt \
@@ -64,8 +62,8 @@ Generate a kubeconfig file suitable for authenticating as the `admin` user:
6462

6563
kubectl config use-context kubernetes-the-hard-way
6664
```
67-
The results of running the command above should create a kubeconfig file in the default location `~/.kube/config` used by the `kubectl` commandline tool. This also means you can run the `kubectl` command without specifying a config.
6865

66+
The results of running the command above should create a kubeconfig file in the default location `~/.kube/config` used by the `kubectl` command line tool. This also means you can run the `kubectl` command without specifying a config.
6967

7068
## Verification
7169

@@ -87,7 +85,7 @@ List the nodes in the remote Kubernetes cluster:
8785
kubectl get nodes
8886
```
8987

90-
```
88+
```text
9189
NAME STATUS ROLES AGE VERSION
9290
node-0 Ready <none> 30m v1.31.2
9391
node-1 Ready <none> 35m v1.31.2

docs/labs/kubernetes-the-hard-way/lab11-pod-network-routes.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,11 @@ tags:
1111
- kubectl
1212
---
1313

14-
This is a fork of the original ["Kubernetes the hard way"](https://github.com/kelseyhightower/kubernetes-the-hard-way) originally written by Kelsey Hightower (GitHub: kelseyhightower).
15-
Unlike the original that bases itself on Debian like distributions for the ARM64 architecture, this fork targets Enterprise Linux distributions such as Rocky Linux running on x86_64 architecture.
16-
1714
# Lab 11: Provisioning Pod Network Routes
1815

19-
Pods scheduled to a node receive an IP address from the node's Pod CIDR range. At this point pods can not communicate with other pods running on different nodes due to missing network [routes](https://cloud.google.com/compute/docs/vpc/routes).
16+
> This is a fork of the original ["Kubernetes the hard way"](https://github.com/kelseyhightower/kubernetes-the-hard-way) originally written by Kelsey Hightower (GitHub: kelseyhightower). Unlike the original that bases itself on Debian like distributions for the ARM64 architecture, this fork targets Enterprise Linux distributions such as Rocky Linux running on x86_64 architecture.
17+
18+
Pods scheduled to a node receive an IP address from the node's Pod CIDR range. At this point pods cannot communicate with other pods running on different nodes due to missing network [routes](https://cloud.google.com/compute/docs/vpc/routes).
2019

2120
In this lab you will create a route for each worker node that maps the node's Pod CIDR range to the node's internal IP address.
2221

@@ -57,7 +56,7 @@ ssh root@node-1 <<EOF
5756
EOF
5857
```
5958

60-
## Verification
59+
## Verification
6160

6261
```bash
6362
ssh root@server ip route
@@ -90,5 +89,4 @@ default via XXX.XXX.XXX.XXX dev ens160
9089
XXX.XXX.XXX.0/24 dev ens160 proto kernel scope link src XXX.XXX.XXX.XXX
9190
```
9291

93-
9492
Next: [Smoke Test](lab12-smoke-test.md)

docs/labs/kubernetes-the-hard-way/lab12-smoke-test.md

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,10 @@ tags:
1111
- kubectl
1212
---
1313

14-
This is a fork of the original ["Kubernetes the hard way"](https://github.com/kelseyhightower/kubernetes-the-hard-way) originally written by Kelsey Hightower (GitHub: kelseyhightower).
15-
Unlike the original that bases itself on Debian like distributions for the ARM64 architecture, this fork targets Enterprise Linux distributions such as Rocky Linux running on x86_64 architecture.
16-
1714
# Lab 12: Smoke Test
1815

16+
> This is a fork of the original ["Kubernetes the hard way"](https://github.com/kelseyhightower/kubernetes-the-hard-way) originally written by Kelsey Hightower (GitHub: kelseyhightower). Unlike the original that bases itself on Debian like distributions for the ARM64 architecture, this fork targets Enterprise Linux distributions such as Rocky Linux running on x86_64 architecture.
17+
1918
In this lab you will complete a series of tasks to ensure your Kubernetes cluster is functioning correctly.
2019

2120
## Data Encryption
@@ -29,7 +28,7 @@ kubectl create secret generic kubernetes-the-hard-way \
2928
--from-literal="mykey=mydata"
3029
```
3130

32-
Print a hexdump of the `kubernetes-the-hard-way` secret stored in etcd:
31+
Print a hexdump of the `kubernetes-the-hard-way` secret stored in `etcd`:
3332

3433
```bash
3534
ssh root@server \
@@ -62,7 +61,7 @@ ssh root@server \
6261
0000015a
6362
```
6463

65-
The etcd key should be prefixed with `k8s:enc:aescbc:v1:key1`, which indicates the `aescbc` provider was used to encrypt the data with the `key1` encryption key.
64+
You need to prefix the `etcd` key with `k8s:enc:aescbc:v1:key1`, which indicates using the `aescbc` provider to encrypt the data with the `key1` encryption key.
6665

6766
## Deployments
6867

@@ -108,7 +107,7 @@ Forwarding from 127.0.0.1:8080 -> 80
108107
Forwarding from [::1]:8080 -> 80
109108
```
110109

111-
In a new terminal make an HTTP request using the forwarding address:
110+
In a new terminal make an HTTP request with the forwarding address:
112111

113112
```bash
114113
curl --head http://127.0.0.1:8080
@@ -126,7 +125,7 @@ ETag: "67a34638-267"
126125
Accept-Ranges: bytes
127126
```
128127

129-
Switch back to the previous terminal and stop the port forwarding to the `nginx` pod by typing `[CTRL]` + `[C]`:
128+
Switch back to the previous terminal and stop the port forwarding to the `nginx` pod by typing ++ctrl+c++:
130129

131130
```text
132131
Forwarding from 127.0.0.1:8080 -> 80
@@ -154,7 +153,7 @@ kubectl logs $POD_NAME
154153

155154
In this section you will verify the ability to [execute commands in a container](https://kubernetes.io/docs/tasks/debug-application-cluster/get-shell-running-container/#running-individual-commands-in-a-container).
156155

157-
Print the nginx version by executing the `nginx -v` command in the `nginx` container:
156+
Print the `nginx` version by executing the `nginx -v` command in the `nginx` container:
158157

159158
```bash
160159
kubectl exec -ti $POD_NAME -- nginx -v
@@ -166,7 +165,7 @@ nginx version: nginx/1.27.4
166165

167166
## Services
168167

169-
In this section you will verify the ability to expose applications using a [Service](https://kubernetes.io/docs/concepts/services-networking/service/).
168+
In this section you will verify the ability to expose applications with a [Service](https://kubernetes.io/docs/concepts/services-networking/service/).
170169

171170
Expose the `nginx` deployment using a [NodePort](https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport) service:
172171

@@ -175,7 +174,7 @@ kubectl expose deployment nginx \
175174
--port 80 --type NodePort
176175
```
177176

178-
> The LoadBalancer service type can not be used because your cluster is not configured with [cloud provider integration](https://kubernetes.io/docs/getting-started-guides/scratch/#cloud-provider). Setting up cloud provider integration is out of scope for this tutorial.
177+
> You cannot use the LoadBalancer service type because your cluster is not configured with [cloud provider integration](https://kubernetes.io/docs/getting-started-guides/scratch/#cloud-provider). Setting up cloud provider integration is out of scope for this tutorial.
179178
180179
Retrieve the node port assigned to the `nginx` service:
181180

@@ -184,9 +183,7 @@ NODE_PORT=$(kubectl get svc nginx \
184183
--output=jsonpath='{range .spec.ports[0]}{.nodePort}')
185184
```
186185

187-
188-
189-
Make an HTTP request using the IP address and the `nginx` node port:
186+
Make an HTTP request with the IP address and the `nginx` node port:
190187

191188
```bash
192189
curl -I http://node-0:${NODE_PORT}

docs/labs/kubernetes-the-hard-way/lab13-cleanup.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,17 +7,15 @@ tags:
77
- lab exercise
88
---
99

10-
This is a fork of the original ["Kubernetes the hard way"](https://github.com/kelseyhightower/kubernetes-the-hard-way) originally written by Kelsey Hightower (GitHub: kelseyhightower).
11-
Unlike the original that bases itself on Debian like distributions for the ARM64 architecture, this fork targets Enterprise Linux distributions such as Rocky Linux running on x86_64 architecture.
12-
13-
1410
# Lab 13: Cleaning Up
1511

12+
> This is a fork of the original ["Kubernetes the hard way"](https://github.com/kelseyhightower/kubernetes-the-hard-way) originally written by Kelsey Hightower (GitHub: kelseyhightower). Unlike the original that bases itself on Debian like distributions for the ARM64 architecture, this fork targets Enterprise Linux distributions such as Rocky Linux running on x86_64 architecture.
13+
1614
In this lab you will delete the compute resources created during this tutorial.
1715

1816
## Compute Instances
1917

20-
Previous versions of this guide made use of GCP resources for various aspects of compute and networking. The current version is agnostic, and all configuration is performed on the `jumpbox`, `server`, or nodes.
18+
Previous versions of this guide made use of GCP resources for various aspects of compute and networking. The current version is agnostic, and you perform all configurations on the `jumpbox`, `server`, or nodes.
2119

2220
Clean up is as simple as deleting all virtual machines you created for this exercise.
2321

docs/labs/kubernetes-the-hard-way/lab2-jumpbox.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
---
22
author: Wale Soyinka
3+
contributors: Steven Spencer
34
tags:
45
- kubernetes
56
- k8s
67
- lab exercise
78
---
89

9-
1010
# Lab 2: Set Up The Jumpbox
1111

1212
In this lab you will set up one of the four machines to be a `jumpbox`. You will use this machine to run commands in this tutorial. While the use of a dedicated machine is to ensure consistency, you can run these commands from just about any machine, including your personal workstation running macOS or Linux.
@@ -56,7 +56,7 @@ pwd
5656

5757
## Download Binaries
5858

59-
Here you will download the binaries for the various Kubernetes components. Store these binaries in the `Downloads` directory on the `jumpbox`. This will reduce the amount of internet bandwidth required to complete this tutorial as you avoid downloading the binaries multiple times for each machine in our Kubernetes cluster.
59+
Here you will download the binaries for the various Kubernetes components. Store these binaries in the `Downloads` directory on the `jumpbox`. This will reduce the amount of internet bandwidth required to complete this tutorial as you avoid downloading the binaries many times for each machine in our Kubernetes cluster.
6060

6161
The `download.txt` file lists the binaries you will download, which you can review using the `cat` command:
6262

@@ -95,7 +95,7 @@ total 557M
9595
-rw-r--r--. 1 root 11M Feb 13 20:19 runc.amd64
9696
```
9797

98-
## Install kubectl
98+
## Install `kubectl`
9999

100100
In this section you will install the `kubectl`, the official Kubernetes client command line tool, on the `jumpbox` machine. You will use `kubectl` to interact with the Kubernetes control plane after provisioning of your cluster completes later in this tutorial.
101101

docs/labs/kubernetes-the-hard-way/lab3-compute-resources.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
---
22
author: Wale Soyinka
3+
contributors: Steven Spencer
34
tags:
45
- kubernetes
56
- k8s
@@ -42,7 +43,7 @@ You will use SSH to configure the machines in the cluster. Verify that you have
4243

4344
If you have `root` SSH access for each of your machines you can skip this section.
4445

45-
By default, a new `Rocky Linux` install disables SSH access for the `root` user. This is for security reasons, as the `root` user has total administrative control of unix-like systems. Weak passwords are very bad for internet connected machines. As mentioned earlier, you are going to enable `root` access over SSH to streamline the steps in this tutorial. Security is a trade-off, and in this case, you are optimizing for convenience.
46+
By default, a new `Rocky Linux` install disables SSH access for the `root` user. This is for security reasons, as the `root` user has total administrative control of unix-like systems. Weak passwords are very bad for internet connected machines. As mentioned earlier, you are going to enable `root` access over SSH to streamline the steps in this tutorial. Security is a trade-off, and in this case, you are optimizing for convenience.
4647

4748
Log on to each machine using SSH and your user account, then switch to the `root` user with the `su` command:
4849

docs/labs/kubernetes-the-hard-way/lab4-certificate-authority.md

Lines changed: 17 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,37 @@
11
---
22
author: Wale Soyinka
3+
contributors: Steven Spencer
34
tags:
45
- kubernetes
56
- k8s
67
- lab exercise
78
---
89

9-
1010
# Lab 4: Provisioning a CA and Generating TLS Certificates
1111

12-
In this lab you will provision a [PKI Infrastructure](https://en.wikipedia.org/wiki/Public_key_infrastructure) using openssl to bootstrap a Certificate Authority, and generate TLS certificates for the following components: kube-apiserver, kube-controller-manager, kube-scheduler, kubelet, and kube-proxy. The commands in this section should be run from the `jumpbox`.
12+
In this lab you will provision a [PKI Infrastructure](https://en.wikipedia.org/wiki/Public_key_infrastructure) using openssl to bootstrap a Certificate Authority, and generate TLS certificates for the following components:
13+
14+
* kube-apiserver
15+
* kube-controller-manager
16+
* kube-scheduler
17+
* kubelet
18+
* kube-proxy
19+
20+
Run commands in this section from the `jumpbox`.
1321

1422
## Certificate Authority
1523

16-
In this section you will provision a Certificate Authority that can be used to generate additional TLS certificates for the other Kubernetes components. Setting up CA and generating certificates using `openssl` can be time-consuming, especially when doing it for the first time. To streamline this lab, I've included an openssl configuration file `ca.conf`, which defines all the details needed to generate certificates for each Kubernetes component.
24+
In this section you will provision a Certificate Authority that you will use to generate additional TLS certificates for the other Kubernetes components. Setting up CA and generating certificates with `openssl` can be time-consuming, especially when doing it for the first time. To streamline this lab, the inclusion of an `openssl` configuration file, `ca.conf`, defines all the details needed to generate certificates for each Kubernetes component.
1725

1826
Take a moment to review the `ca.conf` configuration file:
1927

2028
```bash
2129
cat ca.conf
2230
```
2331

24-
You don't need to understand everything in the `ca.conf` file to complete this tutorial, but you should consider it a starting point for learning `openssl` and the configuration that goes into managing certificates at a high level.
32+
You do not need to understand everything in the `ca.conf` file to complete this tutorial, but you should consider it a starting point for learning `openssl` and the configuration that goes into managing certificates at a high level.
2533

26-
Every certificate authority starts with a private key and root certificate. In this section we are going to create a self-signed certificate authority, and while that's all we need for this tutorial, this shouldn't be considered something you would do in a real-world production environment.
34+
Every certificate authority starts with a private key and root certificate. In this section you are going to create a self-signed certificate authority, and while that is all you need for this tutorial, this is something you should not consider in a real-world production environment.
2735

2836
Generate the CA configuration file, certificate, and private key:
2937

@@ -41,7 +49,8 @@ Results:
4149
ca.crt ca.key
4250
```
4351

44-
!!! Tip:
52+
!!! Tip
53+
4554
To view the details encoded in the generated certificate file (ca.crt), you can use this openssl command `openssl x509 -in ca.crt -text -noout | less`.
4655

4756
## Create Client and Server Certificates
@@ -85,7 +94,7 @@ ls -1 *.crt *.key *.csr
8594

8695
## Distribute the Client and Server Certificates
8796

88-
In this section you will copy the various certificates to every machine at a path where each Kubernetes component will search for its certificate pair. In a real-world environment these certificates should be treated like a set of sensitive secrets as they are used as credentials by the Kubernetes components to authenticate to each other.
97+
In this section you will copy the various certificates to every machine at a path where each Kubernetes component will search for its certificate pair. In a real-world environment, you would treat these certificates as a set of sensitive secrets, because Kubernetes uses these components as credentials to authenticate to each other.
8998

9099
Copy the appropriate certificates and private keys to the `node-0` and `node-1` machines:
91100

@@ -113,6 +122,6 @@ scp \
113122
root@server:~/
114123
```
115124

116-
> The `kube-proxy`, `kube-controller-manager`, `kube-scheduler`, and `kubelet` client certificates will be used to generate client authentication configuration files in the next lab.
125+
> You will use the `kube-proxy`, `kube-controller-manager`, `kube-scheduler`, and `kubelet` client certificates to generate client authentication configuration files in the next lab.
117126
118127
Next: [Generating Kubernetes Configuration Files for Authentication](lab5-kubernetes-configuration-files.md)

0 commit comments

Comments
 (0)