Namespace and Cgroup

  • When you start a container, behind the scenes, Docker creates a set of namespaces and control groups for the container.

What is Namespace?

How To List Docker Images with different options

$ docker images$ docker image ls

Note: Make sure that you have written “image” and not “images”.

2. Filtering Docker Image List

“docker images” command with the “–filter” followed by the filter in…

The docker build command builds Docker images from a Dockerfile

$ docker image build --help

To list the help on any command just execute the above command, followed by the — help option.

Create a Dockerfile with the below content.

FROM nginx:alpineCMD ["nginx", "-g", "daemon off;"]

What is Docker Registry?

  • It allows you to locally store all your Docker images in one centralized location.
  • Docker registry is a repository of Docker images from where you can pull and push images.
  • The registry holds different tagged versions of…

How To Dockerize an Angular Application with multistage build

  • In a multi-stage build, you have a single Dockerfile but can define multiple images inside it to help build the final image.
  • This approach to keeping Docker images small is using multistage builds

Let’s try to…

Shell and Exec Form

Before we begin, it is important to discuss the forms of instructions. Docker ENTRYPOINT and CMD can have two forms:

  • Exec form

The syntax for any command in shell form is:

<instruction> <command>

The syntax for instructions in exec form is:

<instruction> ["executable", "parameter"]

You can write Docker…

Node Sample application

Let’s create a simple Node.js application that we can use as our example.

Create a directory in your local machine named node and follow the steps below to create a simple REST API.

$ mkdir node 
$ cd node
$ apt install npm && npm init -y

Dockerize your Apache with Custom index.html

What is Dockerfile?

  • A Dockerfile describes the software that makes up an image.
  • Dockerfile is a simple text file that consists of instructions to build Docker images.
  • Each instruction present in the docker file represents a layer of the docker image.

Here…

Bikram

Cloud and DevOps Enthusiast

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store