Containerized Deployment Essentials Flashcards

1
Q

What is Docker?

A

A software platform that allows you to create, run, and manage containers on any host system where Docker is installed. In a cloud context, you use Docker to create images locally and then deploy them using cloud services (like Cloud Run) that manage running those containers for you.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is Google Cloud Run?

A

A fully managed compute platform that automatically scales your stateless containers. It abstracts away the underlying infrastructure.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is the purpose of a Dockerfile in the Docker ecosystem?

A

A Dockerfile is a script containing commands that Docker uses to build a Docker image. It specifies the base image to use, the files to add to the image, and the commands to run.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What are the basic steps to build a Docker image from a Dockerfile?

A
  1. Create a Dockerfile, that has necessary packages, copies over the source code, does app build in the container, sets up nginx in the container, runs nginx with ENTRYPOINT
  2. Run the docker build command with the appropriate tags and path to the Dockerfile.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What are the key benefits of using Google Cloud Run for deploying containerized applications?

A

No need to manage servers or clusters; Automatic scaling; Concurrency; Paying only for the resources you use.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

How does a container differ from a virtual machine?

A

You run an image in a container, which ensures consistency across different environments—if an image can be built and run on one machine, it should behave identically on another. Containers are lightweight as they share the host OS and only package the application and its immediate dependencies. In contrast, virtual machines include full copies of an operating system, which makes them heavier but allows for greater isolation and security. This also means VMs require more resources, but they provide extensive configuration options that can be advantageous in environments where control over the virtual hardware is necessary.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is service vs project in Google Cloud Run?

A

A “service” is a deployable unit of code that runs a stateless container, while a “project” is a container for all Cloud resources, providing settings, permissions, and billing for a group of services.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is GCP Artifact Container Registry?

A

Google Cloud Artifact Registry is a single place to manage container images and language packages (artifacts). It supports Docker container registries as well as Maven and npm package repositories.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is container?

A

Containers are a form of operating system virtualization that allows applications to run in isolated environments, ensuring consistency across multiple deployment environments.

Nature: Mutable and can have a writable layer on top of the image.
Purpose: To run applications in an isolated environment. It’s a running instance of the image, actively executing processes.
Lifecycle: Created, started, stopped, and deleted as needed. Changes in a container are not saved back to the image.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is runtime?

A

The environment in which a program or application is executed. It includes software, libraries, and services that provide program instructions to the system’s physical hardware.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is the difference between terms deploy vs push?

A

“Push” refers to uploading your local image to a registry like Docker Hub or GCP Artifact Registry. “Deploy” involves taking the pushed image and running it as a service or application in a production environment.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is an image?

A

A lightweight, standalone, and executable software package that includes everything needed to run a piece of software, such as the code, runtime, libraries, environment variables, and configuration files.

Nature: Read-only and immutable.
Purpose: Serves as a blueprint for creating containers. Think of it as a class definition in object-oriented programming.
Lifecycle: Built once and can be distributed to multiple environments.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly