container
noun
A container is an isolated application process with the files and settings it needs. Containers on the same machine usually share the operating system kernel.
The API runs in a container with the same software versions on the laptop, in the test environment and on the production server.
A container helps software run consistently across environments. The application gets its own filesystem, network configuration and process space. This makes it less dependent on what is already installed on the computer or server. Docker is a well-known platform for building and running containers.
From image to running container
A container starts with an image containing the application, required Glossary · In brieflibraryA library is a collection of reusable software code for a defined task. An application can call that code to use existing functionality.Read more and instructions for execution. The image is the fixed starting point; running it creates a container. You can create several containers from the same image, for example for separate instances or test environments.
Data that must survive the removal of a container is usually stored outside it, for example in a volume or external Glossary · In briefdatabaseA database is a structured collection of data that software can store, retrieve and modify. A database management system controls access to that data.Read more. Network access and limits on CPU and memory are also configured separately.
Container or virtual machine?
A virtual machine contains a complete guest operating system with its own kernel. Containers usually share the host kernel and primarily isolate processes and files. They can therefore often start faster and need less storage and memory than virtual machines.
Sharing a kernel also means a container is not a small virtual machine. The degree of isolation depends on the configuration and runtime. Containers and virtual machines can also be used together: several containers can run on one virtual machine.