...

/

Create the Dockerfile

Create the Dockerfile

Learn how to create and inspect a Dockerfile using the docker init command in Docker Desktop.

Using docker init to create the Dockerfile

In the past, we had to create Dockerfiles manually. Fortunately, newer versions of Docker support the docker init command that analyzes applications and automatically creates Dockerfiles that implement good practices. Run the following command to create a Dockerfile for the app. If your Docker installation doesn’t have the docker init plugin, you’ll have to skip this step.

Note: We are using the Docker CLI, so the docker init ...

Access this course and 1400+ top-rated courses and projects.