Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file removed .DS_Store
Binary file not shown.
23 changes: 23 additions & 0 deletions .github/workflows/deploy-security-silverbackai.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Deploy Security Silverback AI to Cloudflare

on:
push:
branches: [main, master]
paths:
- 'workers/security-silverbackai/**'
workflow_dispatch:

jobs:
deploy:
runs-on: ubuntu-latest
name: Deploy security-silverbackai
steps:
- uses: actions/checkout@v4

- name: Deploy to Cloudflare Workers
uses: cloudflare/wrangler-action@v3
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: bafa242dd95d3fdce72540d20accd0a2
workingDirectory: workers/security-silverbackai
command: deploy
23 changes: 23 additions & 0 deletions .github/workflows/deploy-silverbackai-toolkit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Deploy Silverback AI Toolkit to Cloudflare

on:
push:
branches: [main, master]
paths:
- 'workers/silverbackai-toolkit/**'
workflow_dispatch:

jobs:
deploy:
runs-on: ubuntu-latest
name: Deploy silverbackai-toolkit
steps:
- uses: actions/checkout@v4

- name: Deploy to Cloudflare Workers
uses: cloudflare/wrangler-action@v3
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: bafa242dd95d3fdce72540d20accd0a2
workingDirectory: workers/silverbackai-toolkit
command: deploy
23 changes: 23 additions & 0 deletions .github/workflows/deploy-silverbackai.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Deploy Silverback AI Homepage to Cloudflare

on:
push:
branches: [main, master]
paths:
- 'workers/silverbackai/**'
workflow_dispatch:

jobs:
deploy:
runs-on: ubuntu-latest
name: Deploy silverbackai
steps:
- uses: actions/checkout@v4

- name: Deploy to Cloudflare Workers
uses: cloudflare/wrangler-action@v3
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: bafa242dd95d3fdce72540d20accd0a2
workingDirectory: workers/silverbackai
command: deploy
24 changes: 24 additions & 0 deletions .github/workflows/deploy-stockton-worker.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# .github/workflows/deploy-stockton-worker.yml
name: Deploy Stockton Worker to Cloudflare

on:
push:
branches: [main, master]
paths:
- 'workers/cleantruckcheckstockton/**'
workflow_dispatch:

jobs:
deploy:
runs-on: ubuntu-latest
name: Deploy cleantruckcheckstockton
steps:
- uses: actions/checkout@v4

- name: Deploy to Cloudflare Workers
uses: cloudflare/wrangler-action@v3
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: bafa242dd95d3fdce72540d20accd0a2
workingDirectory: workers/cleantruckcheckstockton
command: deploy
1 change: 1 addition & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@

4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
.DS_Store
node_modules/
.wrangler/
*.log
53 changes: 53 additions & 0 deletions CLAUDE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# CLAUDE.md

This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.

## Project Overview

Multi-property web platform deployed on **Cloudflare Workers**, plus a standalone React security app. All workers share Cloudflare account ID `bafa242dd95d3fdce72540d20accd0a2`.

## Architecture

```
workers/
├── silverbackai/ # Marketing homepage (worker.js → HTML)
├── silverbackai-toolkit/ # AI tools catalog (worker.js → HTML)
├── security-silverbackai/ # Security dashboard (worker.js → HTML + JSON API)
├── cleantruckcheckstockton/ # CARB emissions testing service (worker.js → HTML)
├── silverback-ai-studio/ # Full React + Express security app (NOT a CF Worker)
└── dmc-properties/ # Property management dashboard (static HTML)
```

**Cloudflare Workers** (`silverbackai`, `silverbackai-toolkit`, `security-silverbackai`, `cleantruckcheckstockton`): Single `worker.js` files that return complete HTML inline. Each has a `wrangler.toml` for config and a GitHub Actions workflow for auto-deploy on push to `main`.

**silverback-ai-studio**: React 19 + Express + WebSocket app deployed to Google Cloud Run via AI Studio. Uses Firebase Firestore for event storage, Google Gemini API for AI analysis, and Google Sign-In for auth. Monitors 3875 Ruby St, Oakland.

## Deployment

All Cloudflare Worker deploys use GitHub Actions with `cloudflare/wrangler-action@v3`. Workflows are in `.github/workflows/` and trigger on pushes to `main`/`master` scoped by path (e.g., `workers/silverbackai/**`). Requires `CLOUDFLARE_API_TOKEN` secret.

Custom domain routing is configured in each worker's `wrangler.toml` via `routes` (e.g., `security.silverbackai.agency/*`). DNS records must be configured in Cloudflare dashboard separately.

To manually deploy a worker:
```bash
cd workers/<worker-name>
npx wrangler deploy
```

## Silverback AI Studio Commands

```bash
cd workers/silverback-ai-studio
npm install
npm run dev # Start dev server (Express + Vite, port 3000)
npm run build # Production build via Vite
npm run lint # TypeScript type check (tsc --noEmit)
```

## Key Patterns

- Workers return full HTML as template literals inside `fetch()` handler — all CSS is inlined
- Dark theme with purple accents (`#8b5cf6`) is the brand standard across all sites
- The security-silverbackai worker has `/api/health` and `/api/status` JSON endpoints
- Firebase admin is hardcoded to `bryan@norcalcarbmobile.com` in studio app
- Firestore rules enforce auth and role-based access (admin vs viewer)
Loading