Skip to content

Commit 5375d66

Browse files
committed
migrated chapter 2 to chapter 3
1 parent 74545da commit 5375d66

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+161
-161
lines changed

docs/2-virtual-machines-containers/2.0-overview.md docs/3-virtual-machines-containers/3.0-overview.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# 2.0 Virtual Machines
1+
# 3.0 Virtual Machines
22

33
## Chapter Goals
44

docs/2-virtual-machines-containers/2.1-golden-images.md docs/3-virtual-machines-containers/3.1-golden-images.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
docs/2-virtual-machines-containers/2.1-golden-images.md:
2+
docs/3-virtual-machines-containers/3.1-golden-images.md:
33
category: Virtualization
44
estReadingMinutes: 15
55
exercises:
@@ -24,8 +24,8 @@ docs/2-virtual-machines-containers/2.1-golden-images.md:
2424

2525
**Golden Images** (also called base images or image templates) are machine images with pre-configured operating systems. They typically include specialized configurations, security patches and common libraries and tools. Once a Golden Image is created it can be used to easily and reliably create identical environments on different hardware or virtual machines.
2626

27-
![linux image](img2/linux_light.svg ':size=100x100 :class=light-mode-icon :alt= linux image; light mode')
28-
![linux image](img2/linux_dark.svg ':size=100x100 :class=dark-mode-icon :alt= linux image; dark mode')
27+
![linux image](img3/linux_light.svg ':size=100x100 :class=light-mode-icon :alt= linux image; light mode')
28+
![linux image](img3/linux_dark.svg ':size=100x100 :class=dark-mode-icon :alt= linux image; dark mode')
2929

3030
?> If you have an M1 Mac checkout VirtualBox beta build for arm64. (Note that as of 23/02/2023 the VirtualBox beta build for arm64 did not work)
3131

@@ -74,8 +74,8 @@ This kind of repetitive work is often referred to as toil. Reducing toil from va
7474
>
7575
> *- [Site Reliability Engineering: Eliminating Toil](https://landing.google.com/sre/sre-book/chapters/eliminating-toil/)*
7676
77-
![packer image](img2/packer_light.svg ':size=350x350 :class=light-mode-icon :alt= packer image; light mode')
78-
![packer image](img2/packer_dark.svg ':size=350x350 :class=dark-mode-icon :alt= packer image; light mode')
77+
![packer image](img3/packer_light.svg ':size=350x350 :class=light-mode-icon :alt= packer image; light mode')
78+
![packer image](img3/packer_dark.svg ':size=350x350 :class=dark-mode-icon :alt= packer image; light mode')
7979

8080
> **Packer** is an open source tool for creating identical machine images for multiple platforms from a single source configuration.
8181
>

docs/2-virtual-machines-containers/2.2-local-development.md docs/3-virtual-machines-containers/3.2-local-development.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
docs/2-virtual-machines-containers/2.2-local-development.md:
2+
docs/3-virtual-machines-containers/3.2-local-development.md:
33
category: Virtualization
44
estReadingMinutes: 15
55
exercises:
@@ -33,16 +33,16 @@ An important use case for virtual machines is keeping parity between development
3333

3434
So far the tools we have looked at for building and running images are great for automation and managing complicated infrastructure. However, for developers that want to be able to easily create, use and share environments they are not very convenient. If only we could create and start a virtual machine with just two commands...
3535

36-
![developer image](img2/developer_light.svg ':size=150x150 :class=light-mode-icon :alt= developer image; light mode')
37-
![developer image](img2/developer_dark.svg ':size=150x150 :class=dark-mode-icon :alt= developer image; dark mode')
36+
![developer image](img3/developer_light.svg ':size=150x150 :class=light-mode-icon :alt= developer image; light mode')
37+
![developer image](img3/developer_dark.svg ':size=150x150 :class=dark-mode-icon :alt= developer image; dark mode')
3838

3939
?> Once again if you have an M1 MacBook, default vagrant will not work. As Vagrant by default uses Virtualbox as its provider & Virtualbox does not yet work on M1 macs (as of 23/02/2023) this presents a problem.
4040

4141
#### M1 Alternative Exercise: Vagrant for Docker
4242

4343
1. [Install Vagrant](https://www.vagrantup.com/intro/getting-started/install).
4444

45-
2. Inspect the example code ch2/vagrant_docker_example
45+
3. Inspect the example code ch3/vagrant_docker_example
4646

4747
3. Read the following [vagrant provider](https://developer.hashicorp.com/vagrant/docs/provisioning/docker) [vagrant ssh](https://developer.hashicorp.com/vagrant/docs/vagrantfile/ssh_settings)
4848

docs/2-virtual-machines-containers/2.3-managing-infrastructure.md docs/3-virtual-machines-containers/3.3-managing-infrastructure.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
docs/2-virtual-machines-containers/2.3-managing-infrastructure.md:
2+
docs/3-virtual-machines-containers/3.3-managing-infrastructure.md:
33
category: Virtualization
44
estReadingMinutes: 10
55
exercises:
@@ -24,8 +24,8 @@ In this section, you will be learning how to deploy your golden image (and other
2424

2525
## Delivery Pipeline
2626

27-
![A Jenkins pipeline showing passing build, test, and deploy stages](img2/delivery-pipeline-stages_light.svg ':class=light-mode-img-center')
28-
![A Jenkins pipeline showing passing build, test, and deploy stages](img2/delivery-pipeline-stages_dark.svg ':class=dark-mode-img-center')
27+
![A Jenkins pipeline showing passing build, test, and deploy stages](img3/delivery-pipeline-stages_light.svg ':class=light-mode-img-center')
28+
![A Jenkins pipeline showing passing build, test, and deploy stages](img3/delivery-pipeline-stages_dark.svg ':class=dark-mode-img-center')
2929

3030
Automated delivery pipelines accelerate software delivery and enable faster, safer deployments.
3131
An entire integrated toolchain is necessary to leverage the capabilities of an automated pipeline, orchestrated by a build server. Newly committed code that is pushed to the git server will trigger a webhook and cause the build servers to run certain tasks. General stages of a delivery pipeline include:

docs/2-virtual-machines-containers/2.4-containers.md docs/3-virtual-machines-containers/3.4-containers.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
docs/2-virtual-machines-containers/2.4-containers.md:
2+
docs/3-virtual-machines-containers/3.4-containers.md:
33
category: Containerization
44
estReadingMinutes: 20
55
exercises:
@@ -25,8 +25,8 @@ docs/2-virtual-machines-containers/2.4-containers.md:
2525
>
2626
> _- [What is a Container?](https://www.docker.com/resources/what-container)_
2727
28-
![containers image](img2/containers_light.svg ':size=150x150 :class=light-mode-icon :alt= containers image; light mode')
29-
![containers image](img2/containers_dark.svg ':size=150x150 :class=dark-mode-icon :alt= containers image; light mode')
28+
![containers image](img3/containers_light.svg ':size=150x150 :class=light-mode-icon :alt= containers image; light mode')
29+
![containers image](img3/containers_dark.svg ':size=150x150 :class=dark-mode-icon :alt= containers image; light mode')
3030

3131
Containers allow you to easily package an application's code, configurations, and dependencies into easy to use building blocks. Containers can help ensure that applications deploy quickly, reliably, and consistently regardless of the deployment environment. This enables the following benefits:
3232

@@ -40,8 +40,8 @@ Containers allow you to easily package an application's code, configurations, an
4040

4141
## Containers vs Virtual Machines
4242

43-
![A diagram showing progression from traditional server deployments to virtual machines to container-based deployments](img2/delivery-containers-evolution_light.svg ':class=light-mode-img-center')
44-
![A diagram showing progression from traditional server deployments to virtual machines to container-based deployments](img2/delivery-containers-evolution_dark.svg ':class=dark-mode-img-center')
43+
![A diagram showing progression from traditional server deployments to virtual machines to container-based deployments](img3/delivery-containers-evolution_light.svg ':class=light-mode-img-center')
44+
![A diagram showing progression from traditional server deployments to virtual machines to container-based deployments](img3/delivery-containers-evolution_dark.svg ':class=dark-mode-img-center')
4545

4646
The picture above represents the progression that has happened over the last 15 years in the industry for deploying applications. In the beginning, apps were deployed to their own physical hosts, each with their own operating system.
4747

@@ -61,8 +61,8 @@ Read more from [Docker: What is a Container](https://www.docker.com/resources/wh
6161
6262
Docker is often used synonymously with containers but is actually a platform for using containers. Similar to how Java has development and runtime environments created by different organizations, there are many [other platforms for containers](https://jfrog.com/knowledge-base/6-alternatives-to-docker-all-in-one-solutions-and-standalone-container-tools/) however Docker is by far the most widely adopted container platform.
6363

64-
![docker image](img2/cloud_docker_light.svg ':size=100x100 :class=light-mode-icon :alt= docker image; light mode')
65-
![docker image](img2/cloud_docker_dark.svg ':size=100x100 :class=dark-mode-icon :alt= docker image; light mode')
64+
![docker image](img3/cloud_docker_light.svg ':size=100x100 :class=light-mode-icon :alt= docker image; light mode')
65+
![docker image](img3/cloud_docker_dark.svg ':size=100x100 :class=dark-mode-icon :alt= docker image; light mode')
6666

6767
## Images and Containers
6868
>

docs/2-virtual-machines-containers/2.5.1-docker-compose.md docs/3-virtual-machines-containers/3.5.1-docker-compose.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
docs/2-virtual-machines-containers/2.5.1-docker-compose.md:
2+
docs/3-virtual-machines-containers/3.5.1-docker-compose.md:
33
category: Container Orchestration
44
estReadingMinutes: 5
55
exercises:

docs/2-virtual-machines-containers/2.5.2-kubernetes.md docs/3-virtual-machines-containers/3.5.2-kubernetes.md

+12-12
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
docs/2-virtual-machines-containers/2.5.2-kubernetes.md:
2+
docs/3-virtual-machines-containers/3.5.2-kubernetes.md:
33
category: Container Orchestration
44
estReadingMinutes: 15
55
exercises:
@@ -21,7 +21,7 @@ docs/2-virtual-machines-containers/2.5.2-kubernetes.md:
2121

2222
# Kubernetes
2323

24-
![k8s image](img2/kubernetes.svg ':size=723x702 :class=icon :alt= k8s image')
24+
![k8s image](img3/kubernetes.svg ':size=723x702 :class=icon :alt= k8s image')
2525

2626
There are many different solutions for managing containers but Kubernetes has become one of the most popular and widely used platforms. It is part of a large ecosystem of tools and projects organized by the [Cloud Native Computing Foundation (CNCF)](https://www.cncf.io/) which drives development and support for containerized applications. So what is Kubernetes?
2727

@@ -37,43 +37,43 @@ If you are still having a difficult time understanding what Kubernetes is that i
3737

3838
A Kubernetes **cluster** is a set of node machines for running containerized applications. The Kubernetes Master is a collection of three processes that run on a single node in your cluster, which is designated as the master node. Those processes are: kube-apiserver, kube-controller-manager and kube-scheduler.
3939

40-
![cluster image](img2/delivery-k8s-cluster_light.svg ':class=light-mode-img-center :alt= cluster image; light mode')
41-
![cluster image](img2/delivery-k8s-cluster_dark.svg ':class=dark-mode-img-center :alt= cluster image; dark mode')
40+
![cluster image](img3/delivery-k8s-cluster_light.svg ':class=light-mode-img-center :alt= cluster image; light mode')
41+
![cluster image](img3/delivery-k8s-cluster_dark.svg ':class=dark-mode-img-center :alt= cluster image; dark mode')
4242

4343
### Node
4444

4545
The **nodes** in a cluster are the machines (VMs, physical servers, etc) that run the applications and workflows. The Kubernetes master controls each node.
4646

47-
![delivery k8s node image](img2/delivery-k8s-node_light.svg ':class=light-mode-img-center :alt= delivery k8s node image; light mode')
48-
![delivery k8s node image](img2/delivery-k8s-node_dark.svg ':class=dark-mode-img-center :alt= delivery k8s node image; dark mode')
47+
![delivery k8s node image](img3/delivery-k8s-node_light.svg ':class=light-mode-img-center :alt= delivery k8s node image; light mode')
48+
![delivery k8s node image](img3/delivery-k8s-node_dark.svg ':class=dark-mode-img-center :alt= delivery k8s node image; dark mode')
4949

5050
# Design
5151

5252
Kubernetes is declarative by design. When you want to change something in the cluster, you simply create/update/delete the resources from etcd via the API server. Various controllers then respond to this change by converging the system to comply with the newly declared state. To best understand, check out this drawing from [Julia Evans](https://jvns.ca/blog/2017/06/04/learning-about-kubernetes/):
5353

54-
![scenes from k8s image](img2/scenes-from-kubernetes-page1.svg ':size=600px :class=img-center :alt= scenes from k8s image')
54+
![scenes from k8s image](img3/scenes-from-kubernetes-page1.svg ':size=600px :class=img-center :alt= scenes from k8s image')
5555

5656
?>**Declarative:** you declare what you want the system to do - a desired state - and the system will align towards that state. In Kubernetes, you create an API object to represent what you want the system to do. And all the components in the system work to drive towards that state until the object is deleted.
5757

5858
## Pods
5959

6060
A **Pod** is the basic execution unit of a Kubernetes application – the smallest and simplest unit in the Kubernetes object model that you create or deploy to run containers.
6161

62-
![delivery k8s pod image](img2/delivery-k8s-pods_light.svg ':class=light-mode-img-center :alt= delivery k8s pod image; light mode')
63-
![delivery k8s pod image](img2/delivery-k8s-pods_dark.svg ':class=dark-mode-img-center :alt= delivery k8s pod image; dark mode')
62+
![delivery k8s pod image](img3/delivery-k8s-pods_light.svg ':class=light-mode-img-center :alt= delivery k8s pod image; light mode')
63+
![delivery k8s pod image](img3/delivery-k8s-pods_dark.svg ':class=dark-mode-img-center :alt= delivery k8s pod image; dark mode')
6464

6565
## Services
6666

6767
A **Service** is an abstraction that defines a logical set of Pods and a policy by which to access them. As pods are created, scaled and destroyed over an application's lifetime the node they are running on and their IP addresses will change. A Service provides a consistent way to communicate with a set of pods regardless of how many pods there are or where they are running.
6868

69-
![delivery k8s service image](img2/delivery-k8s-service_light.svg ':class=light-mode-img-center :alt= delivery k8s service image; light mode')
70-
![delivery k8s service image](img2/delivery-k8s-service_dark.svg ':class=dark-mode-img-center :alt= delivery k8s service image; dark mode')
69+
![delivery k8s service image](img3/delivery-k8s-service_light.svg ':class=light-mode-img-center :alt= delivery k8s service image; light mode')
70+
![delivery k8s service image](img3/delivery-k8s-service_dark.svg ':class=dark-mode-img-center :alt= delivery k8s service image; dark mode')
7171

7272
## Deployments
7373

7474
Deployments abstract away the low-level details of managing Pods. Behind the scenes, **Deployments** rely on **Replica Sets** to manage starting, stopping, scaling, and restarting the Pods if they happen to go down for some reason. Below is an example illustration of a deployment.
7575

76-
![delivery k8s deploy image](img2/delivery-k8s-deploy.gif ':class=img-center :alt= delivery k8s deploy image')
76+
![delivery k8s deploy image](img3/delivery-k8s-deploy.gif ':class=img-center :alt= delivery k8s deploy image')
7777

7878
## Labels and Selectors
7979

docs/2-virtual-machines-containers/2.5.3-deliverables.md docs/3-virtual-machines-containers/3.5.3-deliverables.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# Deliverables
22

3-
- Learn how to use Docker Compose to create a containerized local development environment in the [Docker Compose](/2-virtual-machines-containers/2.5.1-docker-compose?id=exercise) exercise.
3+
- Learn how to use Docker Compose to create a containerized local development environment in the [Docker Compose](/3-virtual-machines-containers/3.5.1-docker-compose?id=exercise) exercise.
44

5-
- Familiarize yourself with the basic commands to use a Kubernetes cluster in the [Hello Minikube](/2-virtual-machines-containers/2.5.2-kubernetes?id=exercises) exercise.
5+
- Familiarize yourself with the basic commands to use a Kubernetes cluster in the [Hello Minikube](/3-virtual-machines-containers/3.5.2-kubernetes?id=exercises) exercise.
66

7-
- Learn how to create and manage Kubernetes Deployment and Service resources in the [Deployments and Services](/2-virtual-machines-containers/2.5.2-kubernetes?id=exercise-2-deployments-and-services-with-kubernetes-in-docker-kind) exercise.
7+
- Learn how to create and manage Kubernetes Deployment and Service resources in the [Deployments and Services](/3-virtual-machines-containers/3.5.2-kubernetes?id=exercise-3-deployments-and-services-with-kubernetes-in-docker-kind) exercise.
88

99
- Discuss the following topics:
1010

docs/2-virtual-machines-containers/packer.md docs/3-virtual-machines-containers/packer.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ multiple platforms with all of the software configured at the time the image is
66
built. Packer defines configuration in a JSON file which can be added to
77
version control and increases scalability. It is worth noting Packer is lightweight and is capable of running on every major operating system today and it is very popular to use additional tools such as Chef and Ansible to further install software on the machine image.
88

9-
![packager image](img2/packer.svg ':size=350x350 :class=icon :alt= packer image')
9+
![packager image](img3/packer.svg ':size=350x350 :class=icon :alt= packer image')
1010

1111
## Use cases
1212

@@ -79,6 +79,6 @@ Next Discuss:
7979
- Understand what the engineers are accomplishing with Packer
8080
- Create a presentation about Packer, containerization, and how they are used at the enterprise
8181
- Work with the engineers to have them perform a technical demo during your presentation
82-
- Present your experience with Chapter 2 to the team
82+
- Present your experience with Chapter 3 to the team
8383

8484
</div></div>

0 commit comments

Comments
 (0)