Prerequisites before creating docker container:

  1. install docker by download from official website - https://docs.docker.com/docker-for-mac/install/
  2. share local file system to running docker instance

file-system-sharing-macbook-docker

Before starting the docker container for first time make sure you run the below command to share local file folder with docker instance running on your macbook.

1
docker run -it -v /localFolderName:/folderInDocker dockerContainerName bash

Now folderInDocker should be accessible in docker container.