---
title: Inbound
icon: mail-receive
description: Set up and run the Reloop inbound MX receiver locally in Docker.
---
> For the complete documentation index, see [llms-docs.txt](/llms-docs.txt) or the site index [llms.txt](/llms.txt). Full docs corpus: [llms-full-docs.txt](/llms-full-docs.txt). Prefer markdown URLs (append `.md`) for agent consumption. Product skill: [skill.md](/skill.md).


Inbound KumoMTA MX receiver — accepts external mail, scans with [spam](/docs/setup/backend/spam) (Rspamd), forwards to [inbox](/docs/setup/backend/inbox) via NATS.

<Tip>
Run [`bun setup`](/docs/setup) or `bun docker:up` from the monorepo root. Inbound needs free port `25`.
</Tip>


## Overview

| Property | Value |
| :--- | :--- |
| **Directory** | `apps/backend/inbound` |
| **Docker service** | `inbound` (container `reloop-inbound`) |
| **SMTP port** | `25` |
| **HTTP port** | `8030` (health check) |
| **Stack** | KumoMTA · Lua · [spam](/docs/setup/backend/spam) |


## Quick start

```bash
bun docker:up
```

Health check: [http://localhost:8030/health](http://localhost:8030/health).


## Configuration

Key variables in `local/docker-compose.yml`:

| Variable | Default |
| :--- | :--- |
| `INBOUND_HOSTNAME` | `inbound.reloop.sh` |
| `NATS_URL` | `reloop-nats:4222` |
| `KUMOMTA_RSPAMD_URL` | `http://reloop-spam:11333/checkv2` |
| `KUMOMTA_CHECK_RECIPIENT_URL` | `http://host.docker.internal:8011/api/domain` |


## Commands

| Command | Description |
| :--- | :--- |
| `bun docker:up` | Start full Docker stack (includes inbound) |
| `docker compose -f local/docker-compose.yml up -d inbound` | Start inbound only |
| `docker logs -f reloop-inbound` | Stream logs |
| `curl http://localhost:8030/health` | Health check |


## Architecture

```
External Sender → Port 25 → Recipient Check → Spam (Rspamd) → NATS → Inbox
                                                         ↘ discard (no SMTP egress)
```

| Layer | Detail |
| :--- | :--- |
| **MX reception** | Accepts inbound mail on port `25` |
| **Validation** | [domain](/docs/setup/backend/domain) service verifies recipients |
| **Spam scan** | [spam](/docs/setup/backend/spam) backend scores mail via `/checkv2` |
| **Forwarding** | Accepted messages published to NATS for inbox, then assigned to the `null` queue |
| **Receive-only** | No SMTP AUTH, no HTTP inject, no outbound delivery — submission is [smtp](/docs/setup/backend/smtp) only |


## Next

<CardGroup cols={2}>
  <Card icon="rocket" title="Setup" href="/setup">
    One-command local bootstrap
  </Card>
  <Card icon="globe" title="Port reference" href="/setup/port">
    Port `25` and edge conflicts
  </Card>
  <Card icon="inbox" title="Inbox" href="/setup/backend/inbox">
    Persists messages from NATS
  </Card>
  <Card icon="globe" title="Domain" href="/setup/backend/domain">
    Recipient validation API
  </Card>
  <Card icon="shield" title="Spam" href="/setup/backend/spam">
    Rspamd scan backend for inbound
  </Card>
</CardGroup>
