This guide provides step-by-step installation instructions for different operating systems.
ChatCVE uses Docker for container scanning - Docker daemon required! This provides:
- 🔍 Complete analysis - full access to image layers
- 🎯 Accurate results - analyzes actual installed packages
- ⚡ Reliable detection - proven Docker + Syft + Grype workflow
- 🛠️ Industry standard - uses established container tooling
Before starting, run our prerequisites checker:
./check-prerequisites.shThis will verify all dependencies and guide you through any missing requirements.
sudo apt update && sudo apt upgrade -ysudo apt install -y python3 python3-pip python3-venv nodejs npm git sqlite3 curl docker.io
# Start and enable Docker
sudo systemctl start docker
sudo systemctl enable docker
# Add user to docker group (requires logout/login)
sudo usermod -aG docker $USER# Check Node.js version (should be 18+)
node --version
# If Node.js is too old, install latest LTS:
curl -fsSL https://deb.nodesource.com/setup_lts.x | sudo -E bash -
sudo apt-get install -y nodejsgit clone https://github.com/jasona7/ChatCVE.git
cd ChatCVE
# Create Python virtual environment
python3 -m venv .env
source .env/bin/activate
# Install Python dependencies
pip install flask flask-cors langchain langchain-openai langchain-community
# Install frontend dependencies
cd frontend-next
npm install
cd ..
# Make startup script executable
chmod +x start-chatcve.sh./start-chatcve.sh/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"brew install python@3.10 node npm git sqlitegit clone https://github.com/jasona7/ChatCVE.git
cd ChatCVE
# Create Python virtual environment
python3 -m venv .env
source .env/bin/activate
# Install Python dependencies
pip install flask flask-cors langchain langchain-openai langchain-community
# Install frontend dependencies
cd frontend-next
npm install
cd ..
# Make startup script executable
chmod +x start-chatcve.sh./start-chatcve.sh# For CentOS/RHEL 8+
sudo dnf install -y python3 python3-pip nodejs npm git sqlite
# For older versions, use yum:
# sudo yum install -y python3 python3-pip nodejs npm git sqlite# Install Node.js 18 LTS
curl -fsSL https://rpm.nodesource.com/setup_lts.x | sudo bash -
sudo dnf install -y nodejsgit clone https://github.com/jasona7/ChatCVE.git
cd ChatCVE
# Create Python virtual environment
python3 -m venv .env
source .env/bin/activate
# Install Python dependencies
pip install flask flask-cors langchain langchain-openai langchain-community
# Install frontend dependencies
cd frontend-next
npm install
cd ..
# Make startup script executable
chmod +x start-chatcve.sh./start-chatcve.shOption A: Using Chocolatey (Recommended)
# Install Chocolatey (if not installed)
Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1'))
# Install dependencies
choco install python nodejs git sqlite -yOption B: Manual Installation
- Download and install Python 3.10+
- Download and install Node.js 18+
- Download and install Git
git clone https://github.com/jasona7/ChatCVE.git
cd ChatCVE
# Create Python virtual environment
python -m venv .env
.env\Scripts\activate
# Install Python dependencies
pip install flask flask-cors langchain langchain-openai langchain-community
# Install frontend dependencies
cd frontend-next
npm install
cd ..# Windows users: Use the batch file or run commands manually
# Backend (in one terminal)
.env\Scripts\activate
cd api
python flask_backend.py
# Frontend (in another terminal)
cd frontend-next
npm run devIf you prefer containerized deployment:
# This is a sample - you may need to customize
FROM node:18-alpine AS frontend-builder
WORKDIR /app
COPY frontend-next/package*.json ./
RUN npm ci --only=production
FROM python:3.10-slim
WORKDIR /app
# Install system dependencies
RUN apt-get update && apt-get install -y \
sqlite3 \
&& rm -rf /var/lib/apt/lists/*
# Install Python dependencies
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy application files
COPY . .
COPY --from=frontend-builder /app/node_modules ./frontend-next/node_modules
EXPOSE 3000 5000
CMD ["./start-chatcve.sh"]docker build -t chatcve .
docker run -p 3000:3000 -p 5000:5000 chatcveCreate a .env file in the root directory:
OPENAI_API_KEY=your_openai_api_key_here
NVD_API_KEY=your_nvd_api_key_hereThe SQLite database will be created automatically on first run. For existing data:
# Place your existing app_patrol.db in the root directory
cp /path/to/your/app_patrol.db ./# Ubuntu/Debian
sudo ufw allow 3000
sudo ufw allow 5000
# CentOS/RHEL
sudo firewall-cmd --add-port=3000/tcp --permanent
sudo firewall-cmd --add-port=5000/tcp --permanent
sudo firewall-cmd --reloadAfter installation, verify ChatCVE is working:
- Check Prerequisites:
./check-prerequisites.sh - Start Services:
./start-chatcve.sh - Open Browser: Navigate to
http://localhost:3000 - Test API: Visit
http://localhost:5000/health
Port Conflicts
# Find processes using ports
sudo lsof -ti:3000 | xargs kill -9
sudo lsof -ti:5000 | xargs kill -9Permission Errors
# Fix script permissions
chmod +x start-chatcve.sh
chmod +x check-prerequisites.shPython Module Errors
# Reinstall in virtual environment
source .env/bin/activate # Linux/macOS
# or .env\Scripts\activate # Windows
pip install --upgrade flask flask-cors langchain langchain-openai langchain-communityNode.js Errors
# Clear npm cache and reinstall
cd frontend-next
rm -rf node_modules package-lock.json
npm cache clean --force
npm installAfter successful installation:
- Configure API Keys in Settings (
/settings) - Run Your First Scan in Scans (
/scans) - Explore CVE Database in CVE Explorer (
/cves) - Chat with AI in Chat (
/chat)
If you encounter issues:
- Run
./check-prerequisites.shto diagnose problems - Check our GitHub Issues
- Review the main README.md for additional help
Happy scanning! 🛡️