Docker Automation : DockerFile
FROM base-image
COPY source destination
RUN Command-Line
Metadata Modifffication instructions
WORKDIR /directory/subdirectoy
ENV variable value
VOLUME /mount/point
EXPOSE port
ENTRYPOINT ["/bin/binary", "opt"]
CMD ["opt", "arg"]
.dockerignore file exclude files according to some rules ex for python **/pycache -> excludes the folder pycache from any directory .git -> excludes the .git folder big_files_folder
docker build -t tag -f Dockerfile build_context
-t set names and tags for the Final Image.
build_context is a folder path where all files used withing the doicker builds are located.
-f provides the dockerfile name. Must be in the build_context.
${PWD} : links the current folder in Terminal to the /app folder in the docker image bash : opens a bash prompt on the image. type exit to get out. in the command prompt use python to open the python command prompt. Check version and use exit() to get out.