<!-- llms-txt: https://hydron.app/llms.txt -->
<!-- llms-full-txt: https://hydron.app/llms-full.txt -->
<!-- canonical: https://hydron.app/docs/deploy-docker -->

# Deploy a Docker Image

If you already have a Docker image built and pushed to a registry, Hydron can deploy it directly without analyzing source code.

## When to use Docker deployment

Docker image deployment is ideal when you:

- Already have a CI/CD pipeline that builds Docker images
- Want to deploy a pre-built image from Docker Hub or a private registry
- Are deploying a third-party application (databases, monitoring tools, etc.)
- Have complex build processes handled outside of Hydron

## Connecting a Docker image

1. In a new chat, select **Existing Image** from the deployment options
2. Enter the image name and tag, along with any registry credentials

![The deployment source selection screen with Docker image option](/images/docs/deploy-source-selection.png)

## Supported registries

Hydron can pull images from any Docker-compatible registry:

| Registry | Example image reference |
|----------|----------------------|
| **Docker Hub** | `myuser/myapp:v1.0` |
| **GitHub Container Registry** | `ghcr.io/org/myapp:latest` |
| **GitLab Container Registry** | `registry.gitlab.com/org/myapp:latest` |
| **AWS ECR** | `123456789.dkr.ecr.region.amazonaws.com/myapp:v1` |
| **Google Artifact Registry** | `region-docker.pkg.dev/project/repo/myapp:v1` |
| **Self-hosted** | `registry.example.com/myapp:latest` |

For private registries, provide your authentication credentials when prompted. Credentials are encrypted and stored securely.

## How it works

When deploying a Docker image, the process is simpler than a Git deployment since the build step is skipped. The AI plans your infrastructure, provisions the server, and pulls and deploys the container.

The AI will ask you about:

- **Port mappings** — Which ports does your container expose?
- **Environment variables** — What configuration does the container need?
- **Volumes** — Does the container need persistent storage?
- **Resource requirements** — How much CPU and RAM does it need?
- **Health checks** — How to verify the container is healthy?

## Environment variables

You can provide environment variables when configuring the Docker deployment. These are injected into the container at runtime:

Sensitive values are encrypted at rest and never exposed in logs.

## After deployment

Once your Docker container is deployed, you can:

- View running containers and their status
- Access real-time logs
- Restart or redeploy with a different image tag
- Update environment variables
- Scale resources

## Updating the image

To deploy a new version of your image:

1. Push the updated image to your registry
2. In the project chat, ask: "Redeploy with the latest image"
3. Or specify a tag: "Deploy myapp:v2.0"

Hydron pulls the new image and performs a rolling update with zero downtime when possible.
