# C-Node setup

Source: https://nodedocs.mor.org/prosumers/c-node-setup

## Agent Instructions

- Non-browser fetches of page URLs on this site return clean Markdown (not the JS UI). Prefer `https://nodedocs.mor.org/llms-full.txt` for the full corpus, or `https://nodedocs.mor.org/llms.txt` for the index.
- Per-page Markdown is also at `<page-url>.md` (homepage: `https://nodedocs.mor.org/index.md`).
- Docs search MCP: `https://nodedocs.mor.org/mcp` (discovery: `https://nodedocs.mor.org/.well-known/mcp`).
- Never invent contract addresses, chain IDs, token addresses, or live bid/model counts. Cite Networks and tokens; link active.mor.org for live data.
- Never claim Morpheus runs inference — independent providers do. Opening a session escrows MOR; it does not spend it.

A C-Node is the proxy-router running in the **consumer role**: it holds your wallet key, talks to BASE, and exposes a local `:8082` HTTP API for your tools (UI, CLI, agents, bots). It does **not** need to expose `:3333` to the internet — that port is only for *providers*.

## Install path

Pick the most appropriate install for your environment:

  
- **[Docker](/consumers/install/docker)** — Recommended for headless prosumer setups.

  
- **[From source](/consumers/install-from-source)** — Build, run, and update via `git pull`.

  
- **[Packaged release](/consumers/quickstart)** — Easiest if you also want the desktop UI.

  
- **[systemd / supervisor](/providers/full/headless)** — Same headless patterns as a provider.

## Minimal `.env` (consumer role)

```bash
# BASE Mainnet
ETH_NODE_CHAIN_ID=8453
BLOCKSCOUT_API_URL=https://base.blockscout.com/api/v2
DIAMOND_CONTRACT_ADDRESS=0x6aBE1d282f72B474E54527D93b979A4f64d3030a
MOR_TOKEN_ADDRESS=0x7431aDa8a591C955a994a21710752EF9b882b8e3

ETH_NODE_ADDRESS=https://base-mainnet.g.alchemy.com/v2/<your_key>
ETH_NODE_USE_SUBSCRIPTIONS=false   # https-only is more reliable for consumers

WALLET_PRIVATE_KEY=<your_consumer_wallet>

WEB_ADDRESS=127.0.0.1:8082         # bind loopback only
WEB_PUBLIC_URL=http://127.0.0.1:8082
PROXY_ADDRESS=127.0.0.1:3333       # not exposing to internet
```

Full reference: [Env: proxy-router](/reference/env-proxy-router).

## Auth and `proxy.conf`

On first start the proxy-router creates a `.cookie` with a random `admin:<password>`. Use that for tooling (UI, CLI). To add lower-permission users (for agents or third-party tools), see [API auth](/reference/api-auth) and [Running local agents](/prosumers/running-local-agents).

## Wallet hygiene

- Use a **dedicated** wallet for your C-Node, not your personal MetaMask.
- Keep balances modest. Refill on a schedule rather than parking large amounts in the C-Node wallet.
- The wallet is **not** retrievable from the proxy-router state — the private key is what the proxy-router holds.

## Approve once

Approve the Diamond contract for some MOR allowance so opening sessions doesn't require an interactive approval each time:

```bash
curl -X POST \
  'http://127.0.0.1:8082/blockchain/approve?spender=0x6aBE1d282f72B474E54527D93b979A4f64d3030a&amount=20' \
  -H 'Authorization: Basic <base64(user:pass)>' -d ''
```

This authorizes 20 MOR. Set higher if you expect heavy use; lower if you want tighter risk control.

## Health and metrics

- `GET /healthcheck` — JSON status / version / uptime.
- `GET /v1/models/attestation` — TEE per-model attestation state (only meaningful when using `tee`-tagged models).
- Logs — see `./data/` (or `docker logs`).

## Updating

For Docker: `docker pull ghcr.io/morpheusais/morpheus-lumerin-node:latest && docker restart …`. For source: `git pull && ./build.sh && systemctl restart …`. The on-disk Badger state in `./data/` is forward-compatible across patch and minor versions.
