Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/dataease/SQLBot/llms.txt

Use this file to discover all available pages before exploring further.

The quickest way to get SQLBot running is with a single docker run command. All application services — the FastAPI backend, the MCP server, the G2 chart renderer, and an embedded PostgreSQL database — run inside one container. Data is persisted through volume mounts so the container can be restarted or replaced without data loss.

Prerequisites

Linux server

Any modern Linux distribution with at least 2 CPU cores and 4 GB of RAM.

Docker installed

Docker Engine 20.10 or later. Visit the Docker installation guide if needed.

Deploying the container

1

Pull and start the container

Run the following command from any directory on your server. Docker will pull the latest dataease/sqlbot image and start the container in detached mode.
docker run -d \
  --name sqlbot \
  --restart unless-stopped \
  -p 8000:8000 \
  -p 8001:8001 \
  -v ./data/sqlbot/excel:/opt/sqlbot/data/excel \
  -v ./data/sqlbot/file:/opt/sqlbot/data/file \
  -v ./data/sqlbot/images:/opt/sqlbot/images \
  -v ./data/sqlbot/logs:/opt/sqlbot/app/logs \
  -v ./data/postgresql:/var/lib/postgresql/data \
  --privileged=true \
  dataease/sqlbot
The --privileged=true flag is required because the container starts its own PostgreSQL process. If your security policy prohibits privileged containers, use the Docker Compose deployment with an external database instead.
2

Verify the container is running

Check that the container started successfully and that the health check is passing.
docker ps --filter name=sqlbot
docker logs sqlbot --tail 50
You should see the message PostgreSQL started. followed by the uvicorn startup lines for both the main app (port 8000) and the MCP server (port 8001).
3

Open the web UI

Once the container is healthy, open your browser and navigate to:
http://<your-server-ip>:8000
Log in with the default credentials:
FieldValue
Usernameadmin
PasswordSQLBot@123456
Change the default admin password immediately after your first login. The default password is well-known and must not be used in production.

Volume mounts explained

Each volume mount keeps a specific category of data outside the container so it survives container restarts and upgrades.
Host pathContainer pathPurpose
./data/sqlbot/excel/opt/sqlbot/data/excelExcel files uploaded by users for data import.
./data/sqlbot/file/opt/sqlbot/data/fileGeneral file uploads (documents, attachments).
./data/sqlbot/images/opt/sqlbot/imagesChart images generated by the MCP server and served to clients.
./data/sqlbot/logs/opt/sqlbot/app/logsApplication log files written by the backend.
./data/postgresql/var/lib/postgresql/dataPostgreSQL data directory. Loss of this volume means loss of all data.
Back up ./data/postgresql regularly. It contains your entire database including workspaces, datasource connections, conversation history, and LLM configurations.

Ports explained

PortPurpose
8000Main web UI and REST API. Users access the conversational interface through this port.
8001MCP (Model Context Protocol) server. Used when integrating SQLBot with external agents such as n8n, Dify, or MaxKB.
If you place SQLBot behind a reverse proxy (nginx, Caddy, Traefik), you only need to expose port 8000 publicly. Port 8001 can remain internal if you do not use the MCP integration.

Managing the container

# Stop the container
docker stop sqlbot

# Start it again
docker start sqlbot

# View live logs
docker logs -f sqlbot

# Upgrade to the latest image
docker pull dataease/sqlbot
docker stop sqlbot && docker rm sqlbot
# Re-run the original docker run command above

Build docs developers (and LLMs) love