---
title: Container Requirements
description: Port, health check, and runtime requirements for Atlasflow deployments.
order: 6
---

Atlasflow runs your application as a container on a microVM. Your container must meet these runtime requirements for deployments to become healthy and receive traffic.

## Listen on port 3000

Your application must listen for HTTP traffic on **port 3000** inside the container.

```dockerfile
EXPOSE 3000
```

```javascript
// Node.js example
app.listen(3000, "0.0.0.0");
```

> **Warning:** Bind to `0.0.0.0`, not `127.0.0.1`. Binding to localhost only prevents Atlasflow from reaching your application over the internal network.

Atlasflow's edge proxy forwards incoming HTTP and HTTPS traffic to port 3000 on your container. Custom port configuration is not supported today: port 3000 is the default and expected port.

## Health check on `/`

Atlasflow probes your application to determine whether it's healthy and ready to receive traffic.

| Probe             | Value                  |
| ----------------- | ---------------------- |
| Method            | `GET`                  |
| Path              | `/`                    |
| Interval          | Every 15 seconds       |
| Timeout           | 5 seconds              |
| Success           | HTTP **2xx** response  |
| Failure threshold | 3 consecutive failures |

```javascript
// Express example
app.get("/", (_req, res) => {
  res.status(200).send("ok");
});
```

> **Important:** If your application returns 404, 500, or doesn't respond on `/`, Atlasflow marks the deployment as unhealthy after three failed probes. Unhealthy deployments won't receive production traffic.

The health check runs over Atlasflow's internal network: it does not go through the public internet or your custom domain.

A deployment that never becomes healthy within the deployment window is marked `FAILED`. See [Deployments](/docs/concepts/deployments.md) for the full lifecycle.

## Dockerfile example

A minimal Dockerfile that meets Atlasflow requirements:

```dockerfile
FROM node:22-alpine

WORKDIR /app
COPY package*.json ./
RUN npm ci --omit=dev
COPY . .
RUN npm run build

EXPOSE 3000
ENV HOST=0.0.0.0
ENV PORT=3000

CMD ["node", ".output/server/index.mjs"]
```

## Automatic builds

If you don't provide a Dockerfile, Atlasflow auto-detects your framework and generates a build. Auto-detected applications should still listen on port 3000 and respond on `/`: most framework defaults work out of the box.

## Troubleshooting unhealthy deployments

1. **Check logs**: open the deployment runtime logs in the dashboard.
2. **Verify port**: confirm your process listens on `0.0.0.0:3000`.
3. **Test `/`**: ensure `GET /` returns 200, not a redirect to a login page that returns 302.
4. **Startup time**: if your app takes longer than ~45 seconds to start, it may fail the initial health checks. Optimize cold start or defer heavy initialization.

## Next steps

- [Deploy your first project](/docs/guides/first-deployment.md): full deployment walkthrough.
- [Environment variables](/docs/guides/environment-variables.md): configure build and runtime values.
- [Troubleshooting](/docs/resources/troubleshooting.md): fix unhealthy deployments and build failures.