---
title: "Hosted HTTP"
description: "Run nasa-mcp as a stateless Streamable HTTP service in a container behind a TLS-terminating reverse proxy."
type: Guide
tags:
  - deploy
  - docker
  - http
generated:
  by: "claude/opus-5.5"
  at: "2026-11-27T00:00:00Z"
sources:
  - id: design
    resource: "DESIGN.md"
    title: "nasa-mcp design"
    author: "team:nasa-mcp"
status: stable
---

<!--
SPDX-FileCopyrightText: 2026 Tyson Lee Swetnam
SPDX-License-Identifier: CC-BY-4.0
-->

# Hosted HTTP

```bash
docker compose up --build        # publishes 127.0.0.1:8080 only
curl -s http://127.0.0.1:8080/healthz
```

The image (two-stage `python:3.13-slim` and `uv`, both pinned by digest; dependencies from the
hash-locked `uv.lock`) runs as uid 10001 with `NASA_MCP_SERVER__TRANSPORT=http` on `0.0.0.0:8080`
inside the container, a `HEALTHCHECK` on `/healthz`, and a read-only root file system in the
compose file.

For anything public:

* terminate TLS in a reverse proxy and set `NASA_MCP_SERVER__PUBLIC_BASE_URL` (its host is added
  to the DNS-rebinding allow-list), or list hosts in `NASA_MCP_SERVER__ALLOWED_HOSTS`;
* add access control in the proxy if you need it (the server is anonymous and read-only);
* decide about the key. By default HTTP callers get DEMO_KEY (about ten NeoWs/InSight requests per
  IP before a block of about a day, shared by every caller behind your egress IP). Setting
  `NASA_MCP_NASA__API_KEY` **and** `NASA_MCP_NASA__ALLOW_KEY_IN_HTTP_MODE=true` lends your personal
  quota (1,000 requests/hour) to every caller. Pass the key from a secret store, never from a
  committed compose file. The other 14 services are keyless either way;
* to hide services, set `NASA_MCP_SERVICES__DISABLED` (for example `insight,neows`);
* the in-memory cache is per process; set `NASA_MCP_CACHE__DISK_DIR` to a volume for a shared
  gzip-JSON disk cache;
* `/readyz` answers 200 as soon as the process is up.
