# Containers

![](/files/-LvOG4k3uFKDVoAjohIO)

Containers are lightweight, secure, and portable environments designed for developing, testing, and hosting software applications.  Containers run on top of VMs or bare-metal servers and were pioneered by  a company called [Docker](https://www.docker.com/resources/what-container).  They have recently become popular in the ML industry.

Container **orchestration** is dominated by Kubernetes, an open source system for automating and scaling application deployment.&#x20;

Container **registries** are where containers are hosted.  Examples include DockerHub and Amazon ECR.

A Docker file is a set of instructions (software packages to include) in a Docker image.  Deploying applications using Docker containers is straightforward.

* Build: Create an image from a Docker file
* Push: Save image in a registry
* Run: Application can be run anywhere
* Pull: Download containers from a registry

Docker tags specify a version e.g. `username/image_name:tag_name`&#x20;

## Containers + Gradient

Gradient can run any Docker container (for Notebooks, Experiments, Jobs, and Deployments) hosted on a public or private container registry.

Gradient maintains a list of [containers](https://docs.paperspace.com/gradient/notebooks/notebook-containers) pre-loaded with various up-to-date ML frameworks, libraries, drivers, and more.

Gradient also includes a way to build containers from a Dockerfile without any expertise in Docker itself.&#x20;

### Related Material

{% embed url="<https://docs.paperspace.com/gradient/notebooks/notebook-containers/building-a-custom-container>" %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://machine-learning.paperspace.com/wiki/containers.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
