Device telemetry, remote command execution, alerting, and fleet management for Windows, Linux, and macOS endpoints.
- Build agent release binaries:
bash scripts/build-release.sh- Run the production setup:
bash scripts/setup-prod.sh- Access the UI and API:
- Dashboard:
https://YOUR_DOMAIN - API docs:
https://YOUR_DOMAIN/docs
make dev
make dev-agent| Requirement | Version | Notes |
|---|---|---|
| Docker | 24+ | Needed for local PostgreSQL, Redis, and the full stack |
| Go | 1.22 | Required for the agent build and tests |
| Node.js | 20 | Required for the frontend build and dev server |
| Python | 3.12 | Required for the FastAPI server and Alembic |
+-----------------------+
| React UI |
| Dashboard / Alerts |
+-----------+-----------+
|
| HTTPS / REST
v
+-------------+ +--------+---------+ +------------------+
| Go Agent | <----> | FastAPI API | <----> | PostgreSQL / |
| telemetry | WS | WebSocket broker | | TimescaleDB |
| commands | | auth / alerts | +------------------+
+-------------+ +--------+---------+ ^
| |
v |
+------+-------+ |
| Redis cache | <-------------------+
| rate limits |
| enrollment |
+--------------+
- Install prerequisites:
docker --version
node --version
go version
python3 --version- Create and review environment settings:
cp .env.example .env- Start infrastructure:
docker compose up -d postgres redis- Install server dependencies:
cd server
python3 -m pip install --user --break-system-packages uv
~/.local/bin/uv venv .venv
~/.local/bin/uv pip install --python .venv/bin/python -e ".[dev]"- Apply database migrations:
cd server
.venv/bin/alembic upgrade head- Install frontend dependencies:
cd frontend
npm install- Build or run the client agent:
cd client
go mod tidy
go build ./...- Start the dev services:
make dev-server
make dev-frontend
make dev-agentOne-line install example:
curl -fsSL https://your-server.example.com/install-agent.sh | sudo bash -s -- \
--server https://your-server.example.com \
--token REPLACE_METhen install the service:
sudo cp client/packaging/linux/dtsys-agent.service /etc/systemd/system/
sudo systemctl daemon-reload
sudo systemctl enable --now dtsys-agentRun the packaged installer from an elevated PowerShell session:
Set-ExecutionPolicy Bypass -Scope Process -Force
.\client\packaging\windows\install.ps1 `
-ServerURL "https://your-server.example.com" `
-EnrollmentToken "REPLACE_ME"The installer:
- Downloads
dtsys-agent-windows.exe - Writes
agent.toml - Installs the service with NSSM
- Falls back to Chocolatey or a direct NSSM zip download when NSSM is not already present
Copy the binary and config:
mkdir -p /usr/local/lib/dtsys /etc/dtsys
cp dist/agents/dtsys-agent-darwin-arm64 /usr/local/lib/dtsys/dtsys-agent
chmod +x /usr/local/lib/dtsys/dtsys-agent
cp client/packaging/macos/com.dtsys.agent.plist ~/Library/LaunchAgents/
launchctl load ~/Library/LaunchAgents/com.dtsys.agent.plist| Variable | Default | Description |
|---|---|---|
DATABASE_URL |
postgresql+asyncpg://dtsys:dtsys@localhost:5432/dtsys |
Primary SQL database |
REDIS_URL |
redis://localhost:6379/0 |
Redis for enrollment tokens and WS rate limits |
SECRET_KEY |
dev-secret-key-change-in-production |
JWT signing key |
ACCESS_TOKEN_EXPIRE_MINUTES |
60 |
Access token lifetime |
REFRESH_TOKEN_EXPIRE_DAYS |
30 |
Refresh token lifetime |
ENROLLMENT_TOKEN_EXPIRE_MINUTES |
60 |
Enrollment token TTL |
ENVIRONMENT |
development |
Controls startup behavior and docs exposure |
APP_NAME |
DTSYS |
Service name used in responses |
DEVICE_OFFLINE_THRESHOLD_SECONDS |
120 |
Offline detection threshold |
ALERT_CPU_PERCENT |
90.0 |
CPU usage alert threshold |
ALERT_RAM_PERCENT |
90.0 |
RAM usage alert threshold |
ALERT_DISK_PERCENT |
90.0 |
Disk usage alert threshold |
ALERT_CPU_TEMP_CELSIUS |
85.0 |
CPU temperature alert threshold |
ALERT_NTP_OFFSET_MS |
500.0 |
NTP drift alert threshold |
FIRST_ADMIN_PASSWORD |
changeme |
Seeded admin password |
AGENT_VERSION |
0.1.0 |
Version served to auto-updating agents |
AGENT_DIST_DIR |
./dist/agents/ |
Directory exposed by /api/v1/downloads/* |
| Endpoint | Method | Purpose |
|---|---|---|
/api/v1/auth/login |
POST |
Login and receive access / refresh tokens |
/api/v1/auth/refresh |
POST |
Refresh access token |
/api/v1/devices/register |
POST |
Agent registration using enrollment token |
/api/v1/devices |
GET |
List managed devices |
/api/v1/devices/{id} |
GET |
Device details |
/api/v1/devices/{id}/network |
GET |
Latest network interface snapshot |
/api/v1/devices/{id}/commands |
POST |
Dispatch a command to one device |
/api/v1/commands/bulk |
POST |
Dispatch a command to many devices |
/api/v1/alerts |
GET |
Query alerts |
/api/v1/alerts/{id}/resolve |
POST |
Resolve an alert |
/api/v1/agent/version |
GET |
Agent update metadata |
/api/v1/downloads/{filename} |
GET |
Download agent binaries |
/api/v1/agent/download |
GET |
Download agent binary by arch/platform |
/health |
GET |
App, DB, Redis, and uptime health status |
Build the frontend:
make build-frontendBuild all agent binaries:
make build-agentsStart the full local stack:
make docker-upStop it:
make docker-downServer tests:
make test-serverClient tests:
make test-clientRun migrations:
make migrate- Verify
server.urlinagent.toml - Confirm the device can reach
/ws/device/{id}?token=... - Check Redis rate limiting if repeated connection attempts are being rejected with close code
4029
- Ensure the enrollment token exists in Redis and has not been used already
- Confirm the server can write to PostgreSQL during registration
- Verify
server.urlpoints to the API host, not a local-only address
- Check
/healthfor database and Redis status - Confirm telemetry messages are arriving over WebSocket
- Review thresholds in
server/app/config.py
- Rebuild with
make build-frontend - Confirm the browser has a fresh access token
- Inspect
/api/v1/alertsand/api/v1/devicesresponses directly
- Create a feature branch.
- Keep changes scoped and run the relevant build/test targets.
- Add or update tests for any behavior change.
- Run
make lint-server,make test-server, andmake test-clientbefore opening a PR. - Document any operator-facing change in this README.