Building an image in Docker --------------------------- Simple build '''''''''''' To build a container you can simply type: .. code-block:: shell $docker image build . .. warning:: This . at the end represents the context, where . means all files in this directory and subdirectory must be passed into the docker daemon for the build. However this requires that you have a Dockerfile in the directory. For any different cas you will need to use the flags below to control how the code will assemble the image. Some of the flags available are the following: +------------------------------------------+---------------------------------------------------+ | Flag | Effect | +==========================================+===================================================+ | | -t | | Tags the image as . | +------------------------------------------+---------------------------------------------------+ | | -f | | Gives the build the path to a Dockerfile. | +------------------------------------------+---------------------------------------------------+ For more advanced commands refer to the official Docker documentation_. .. _documentation: https://docs.docker.com/engine/reference/commandline/build/