<style> .present { text-align: left; } </style> --- ###### tags: `Week 19` `W19D1` --- # Docker Intro and Week 19 Roadmap --- ## Week 19 topics - Intro and installation (today) - Docker Containers & Images (Tuesday) - AWS Lecture (Wednesday) - Group Project Practice (Thursday) - Project Starter Released (Friday) --- ### Docker Containers & Images (Tuesday) - A docker container is a lightweight package which contains only the software and dependencies we need to run a single process - A container is a running image - We'll explore containers & use the command line interface to work with them - Images are templates for building docker containers - Images allow you to make the same container over and over - We can customize/build our own images using a Dockerfile --- ### AWS (Wednesday) - Learn how to integrate AWS into our project for media storage - Flask/React refactor practice - EOD on Scorecard Grading --- ### Group Project Practice (Thursday) - Practice project for your group! --- ### Project Begins! (Friday) - Finishing up all project documentation - Mark Rodriguez talks to us about ~the future~! - Walkthrough the project starter --- ## What is Docker? ![shipping container](https://upload.wikimedia.org/wikipedia/commons/thumb/1/1c/MAERSK_MC_KINNEY_M%C3%96LLER_%26_MARSEILLE_MAERSK_%2848694054418%29.jpg/1920px-MAERSK_MC_KINNEY_M%C3%96LLER_%26_MARSEILLE_MAERSK_%2848694054418%29.jpg) Docker is a platform that allows for development and deployment of software in packages called *containers*. --- ### Docker containers - Containers are: - **Isolated:** They do not interact with your local filesystem/OS or other containers (unless we configure them to do so) - **Ephemeral:** They can be deleted (& recreated) easily without worry - **Lightweight:** They are single-purpose and contain only what they need for that purpose - **Reproducible:** We can rebuild the same container over & over with a single command --- ### How does Docker work? #### Part 1: Your Computer - In order to understand Docker, we should first discuss how our computers work to begin with. - Your computer has physical hardware, an OS, and a kernel that interfaces between the two, which are all tightly coupled. - When we build & deploy apps with this environment, we are limited to the performance of our machine and the libraries that are compatible with it. --- ### How does Docker work? #### Part 2: Why not use a VM? - A VM has an OS that is *decoupled* from your computer's hardware. With VMs, can have multiple OSs running on a computer. - A VM has a kernel & hypervisor. The kernel interfaces between the hardware and the OS. The hypervisor creates & runs a VM. - A VM is heavy - we often don't need an entirely separate kernel & hypervisor just for the purposes of deploying an application. --- ### VM Visualization <img src="https://k21academy.com/wp-content/uploads/2020/06/Virtual_Machine_Architecture.png" /> --- ### How does Docker work? #### Part 3: Docker containers - A Docker container is like a mini-VM that is hardware agnostic - it doesn't care about the host OS. - It is lightweight - it consists only of a small Linux distribution and necessary libraries & resources. It does not have its own kernel or hypervisor. - This makes it much more scalable and allows us to run many more containers on one machine than VMs. --- ### Docker Visualization <img src="https://k21academy.com/wp-content/uploads/2020/06/output-onlinepngtools-16.png" /> --- ### Virtual Machine vs Docker <img src="https://k21academy.com/wp-content/uploads/2020/05/2020_05_13_12_19_07_PowerPoint_Slide_Show_Azure_AZ104_M01_Compute_ed1_-1024x467.png" /> --- ### Cool... but why are we learning about Docker? - We can easily scale an application using a cluster of containers on one or more machines - We can easily share our application with others for testing & development - We can build a template for our application called an *image* - We can automate the process of building & deploying that image with *docker compose* - We can run the same application on *any* machine without worrying about performance or incompatibilites --- ### Group Project Planning We will have time allotted each day this week to work on group project planning! Use schedule from `Section-2-Resources/Module-6-Resources/group_project_resources/Flask-Group-Project.md` to help guide your planning this week. ***You will be required to have 4 features for this project, 2 full CRUD and 2 partial CRUD*** --- ### Today's itinerary [1/2] 1. Docker introduction - [Docker video](https://www.youtube.com/watch?v=YFl2mCHdv24&ab_channel=JakeWright) 2. Docker installation (if not already installed): - [Docker Products](https://www.docker.com/products/docker-desktop/) - If you want to test your installation: - `docker container run --rm hello-world` - NOTE FOR WSL USERS: You must upgrade to WSL2 to use Docker --- ### Today's itinerary [2/2] Start meeting with your groups and project planning!
{"metaMigratedAt":"2023-06-16T03:42:41.387Z","metaMigratedFrom":"Content","title":"Docker Intro and Week 19 Roadmap","breaks":false,"description":"shipping container","contributors":"[{\"id\":\"dafd1858-850b-4d12-9d53-a1ac5e891cf8\",\"add\":6779,\"del\":7044},{\"id\":\"a6f34c0b-3567-4ed5-ba81-c2299c2d9369\",\"add\":6457,\"del\":3759},{\"id\":\"b3d4b64b-bcb9-47ce-975c-f84011d6c2f4\",\"add\":2827,\"del\":0},{\"id\":\"bbda4bdc-50a5-429e-9073-d74141f277f3\",\"add\":282,\"del\":482}]"}
    1100 views
   Owned this note