Docker – Image/Container build

1. Building an image by pulling

Command:

For example, I recently used:


2. Building an image using Dockerfile

Create “Dockerfile” in your directory, and include the followings in the file:

There are other commands you can contain.


3. Creating a container based on an existing image

For example,


+ If you want to access to a container via VScode:

  1. Right-click on the container
  2. Select “Attach Visual Studio Code”

Leave a Reply

Your email address will not be published. Required fields are marked *