Skip to content

Commit e21a5d2

Browse files
committed
docs: add note about Docker login requirement for public namespaced images
- Clarify that public Docker Hub images with namespaces (e.g., michaelf34/infinity) require docker login - Add section explaining public AWS ECR images work without auth - Link to private registry docs for private ECR setup
1 parent 77f6624 commit e21a5d2

File tree

1 file changed

+32
-0
lines changed

1 file changed

+32
-0
lines changed

cerebrium/container-images/defining-container-images.mdx

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,38 @@ docker_base_image_url = "python:3.11-bookworm"
231231
add only essential components as needed.
232232
</Tip>
233233

234+
#### Public Docker Hub Images with Namespaces
235+
236+
When using public Docker Hub images that include a namespace (e.g., `michaelf34/infinity`, `huggingface/transformers`), you need to be logged in to Docker Hub locally, even though the image is public. This is because Cerebrium reads your `~/.docker/config.json` to authenticate image pulls.
237+
238+
```bash
239+
# Login to Docker Hub (required for namespace/image format)
240+
docker login
241+
```
242+
243+
After logging in, you can use the image in your configuration:
244+
245+
```toml
246+
[cerebrium.deployment]
247+
docker_base_image_url = "michaelf34/infinity:latest"
248+
```
249+
250+
<Note>
251+
Official Docker Hub images without a namespace (like `python:3.11`, `debian:bookworm`, `ubuntu:22.04`)
252+
work without requiring a Docker login. Only images in the `namespace/image` format require authentication.
253+
</Note>
254+
255+
#### Public AWS ECR Images
256+
257+
Public ECR images from the `public.ecr.aws` registry work without authentication:
258+
259+
```toml
260+
[cerebrium.deployment]
261+
docker_base_image_url = "public.ecr.aws/lambda/python:3.11"
262+
```
263+
264+
However, **private ECR images** (e.g., `123456789.dkr.ecr.us-east-1.amazonaws.com/my-image`) require authentication. See [Using Private Docker Registries](/cerebrium/container-images/private-docker-registry) for setup instructions.
265+
234266
## Custom Runtimes
235267

236268
While Cerebrium's default runtime works well for most apps, teams often need more control over their server implementation. Custom runtimes enable features like custom authentication, dynamic batching, public endpoints, or WebSocket connections.

0 commit comments

Comments
 (0)