Add system design notebook image

As well as two Kubernetes basic exercises.
This commit is contained in:
abregman 2021-07-12 04:26:03 +03:00
parent e54648d47f
commit e1379fb6b5
6 changed files with 56 additions and 5 deletions

View File

@ -73,7 +73,7 @@
<td align="center"><a href="#mongo"><img src="images/mongo.png" width="75px;" height="75px;" alt="Mongo"/><br /><b>Mongo</b></a></td> <td align="center"><a href="#mongo"><img src="images/mongo.png" width="75px;" height="75px;" alt="Mongo"/><br /><b>Mongo</b></a></td>
<td align="center"><a href="#puppet"><img src="images/puppet.png" width="75px;" height="75px;" alt="puppet"/><br /><b>Puppet</b></a></td> <td align="center"><a href="#puppet"><img src="images/puppet.png" width="75px;" height="75px;" alt="puppet"/><br /><b>Puppet</b></a></td>
<td align="center"><a href="#distributed"><img src="images/distributed.png" width="110px;" height="75px;" alt="Distributed"/><br /><b>Distributed</b></a></td> <td align="center"><a href="#distributed"><img src="images/distributed.png" width="110px;" height="75px;" alt="Distributed"/><br /><b>Distributed</b></a></td>
<td align="center"><a href="#questions-you-ask"><img src="images/you.png" width="110px;" height="75px;" alt="you"/><br /><b>Questions you can ask</b></a></td> <td align="center"><a href="#questions-you-ask"><img src="images/you.png" width="90px;" height="75px;" alt="you"/><br /><b>Questions you can ask</b></a></td>
</tr> </tr>
</table> </table>
</center> </center>
@ -5220,7 +5220,9 @@ Because each container has its own writable container layer, and all changes are
|Name|Topic|Objective & Instructions|Solution|Comments| |Name|Topic|Objective & Instructions|Solution|Comments|
|--------|--------|------|----|----| |--------|--------|------|----|----|
|My First Pod|Dockerfile|WIP|WIP | My First Pod | Pods | [Exercise](exercises/kubernetes/pods_01.md) | [Solution](exercises/kubernetes/solutions/pods_01_solution.md)
| Creating a service | Service | [Exercise](exercises/kubernetes/services_01.md) | [Solution](exercises/kubernetes/solutions/services_01_solution.md)
### Kubernetes Self Assesment ### Kubernetes Self Assesment
@ -6342,13 +6344,15 @@ View more [here](https://www.youtube.com/watch?v=rDCWxkvPlAw)
<details> <details>
<summary>What is Helm?</summary><br><b> <summary>What is Helm?</summary><br><b>
Package manager for Kubernetes. Basically the ability to package YAML files and distribute them to other users. Package manager for Kubernetes. Basically the ability to package YAML files and distribute them to other users and apply them in different clusters.
</b></details> </b></details>
<details> <details>
<summary>Why do we need Helm? What would be the use case for using it?</summary><br><b> <summary>Why do we need Helm? What would be the use case for using it?</summary><br><b>
Sometimes when you would like to deploy a certain application to your cluster, you need to create multiple YAML files / Components like: Secret, Service, ConfigMap, etc. This can be tedious task. So it would make sense to ease the process by introducing something that will allow us to share these bundle of YAMLs every time we would like to add an application to our cluster. This something is called Helm. Sometimes when you would like to deploy a certain application to your cluster, you need to create multiple YAML files/components like: Secret, Service, ConfigMap, etc. This can be tedious task. So it would make sense to ease the process by introducing something that will allow us to share these bundle of YAMLs every time we would like to add an application to our cluster. This something is called Helm.
A common scenario is having multiple Kubernetes clusters (prod, dev, staging). Instead of individually applying different YAMLs in each cluster, it makes more sense to create one Chart and install it in every cluster.
</b></details> </b></details>
<details> <details>
@ -11724,7 +11728,7 @@ Bonus: extract the last word of each line
<summary>Replace 'red' with 'green'</summary><br><b> <summary>Replace 'red' with 'green'</summary><br><b>
</b></details> </b></details>
#### System Design ## System Design
<details> <details>
<summary>Explain what is a "Single point of failure" and give an example</summary><br><b> <summary>Explain what is a "Single point of failure" and give an example</summary><br><b>

View File

@ -0,0 +1,11 @@
## Pods 01
#### Objective
Learn how to create pods
#### Instructions
1. Choose a container image (e.g. redis, nginx, mongo, etc.)
2. Create a pod (in the default namespace) using the image you chose
3. Verify the pod is running

View File

@ -0,0 +1,11 @@
## Services 01
#### Objective
Learn how to create services
#### Instructions
1. Create a pod running ngnix
2. Create a service for the pod you've just created
3. Verify the app is reachable

View File

@ -0,0 +1,6 @@
## Pods 01 - Solution
```
kubectl run nginx --image=nginx --restart=Never
kubectl get pods
```

View File

@ -0,0 +1,19 @@
## Services 01 - Solution
```
kubectl run nginx --image=nginx --restart=Never --port=80 --labels="app=dev-nginx"
cat << EOF > nginx-service.yaml
apiVersion: v1
kind: Service
metadata:
name: nginx-service
spec:
selector:
app: dev-nginx
ports:
- protocol: TCP
port: 80
targetPort: 9372
EOF
```

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB