DEV Community

Cover image for โšก From `git clone` to Full Company Operating System in 60 Seconds.
Mamoor Ahmad
Mamoor Ahmad Subscriber

Posted on Edited on

โšก From `git clone` to Full Company Operating System in 60 Seconds.

โšก From git clone to Full Company Operating System in 60 Seconds.

HiveOps โ€” One command to rule them all


โฑ๏ธ Seriously. 60 Seconds.

You're a developer. You don't want to read a 40-page setup guide. You don't want to "contact sales." You don't want to configure 12 integrations before you see a dashboard.

You want to run a command and see something working.

That's exactly what HiveOps does.

git clone https://github.com/mamoor123/hiveops.git && cd hiveops
cp .env.example .env
openssl rand -base64 32  # paste into .env as JWT_SECRET
docker-compose up --build
๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung ๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung

Open http://localhost:3000. Done. ๐ŸŽ‰

You now have a full company operating system running on your machine. Let me show you what's inside. ๐Ÿ“ฆ


๐Ÿง  Wait โ€” What Did I Just Deploy?

A complete, production-ready platform that handles:

Module What It Does
๐Ÿ“‹ Task Management Create, assign, track โ€” with priorities, statuses, comments, and file attachments
๐Ÿค– AI Agents Per-department agents that autonomously execute tasks
โš™๏ธ Workflow Engine Triggers โ†’ Conditions โ†’ Actions. Your ops logic, automated
๐Ÿ“ง Real Email SMTP + IMAP. Inbox, drafts, replies. AI drafts responses for you
๐Ÿ“š Knowledge Base Articles with full-text search
๐Ÿ’ฌ Real-Time Chat Channel-based messaging with Socket.IO
๐Ÿ“Š Dashboard Live stats on tasks, agents, emails, and workflows
๐Ÿ” Auth System JWT tokens, role-based access, brute-force protection

All in one Docker Compose file. ๐Ÿณ


๐Ÿ” What Happened in Those 60 Seconds?

Let me break down what docker-compose up actually started:

๐Ÿ—„๏ธ 1. PostgreSQL 16

A full database with 14 tables โ€” ready to go.

users | departments | agents | tasks | task_comments | messages
knowledge_base | workflows | workflow_logs | emails
notifications | uploads | scheduled_tasks | schema_migrations
๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung ๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung

No migrations to run manually. The app handles it on boot. โœ…

๐Ÿ–ฅ๏ธ 2. The API Server (Node.js + Express)

Running on port 3001. Serving 12+ route modules:

# Auth
POST /api/auth/register     โ†’ Create account
POST /api/auth/login        โ†’ Get JWT token
GET  /api/auth/me           โ†’ Current user

# Tasks
GET  /api/tasks             โ†’ List tasks (filterable)
POST /api/tasks             โ†’ Create task
GET  /api/tasks/:id         โ†’ Task detail

# AI Agents
POST /api/ai/chat/:agentId        โ†’ Chat with agent
POST /api/ai/execute/:taskId      โ†’ Execute task via agent
POST /api/ai/delegate             โ†’ Agent-to-agent delegation

# Workflows
POST /api/workflows         โ†’ Create workflow
POST /api/workflows/:id/toggle    โ†’ Enable/disable

# Email
GET  /api/email/folder/:folder    โ†’ List emails
POST /api/email/send              โ†’ Send email

# Knowledge Base
POST /api/knowledge/search        โ†’ Full-text search
๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung ๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung

๐ŸŽจ 3. The Frontend (Next.js 14)

Running on port 3000. App Router. 12 pages covering every module.


๐Ÿค– The AI Agents โ€” This Is Where It Gets Interesting

Most "AI integrations" are chat widgets. Type a question, get an answer. That's it.

HiveOps agents are workers. ๐Ÿ’ช

๐Ÿข One agent per department

๐Ÿ“ฃ Marketing Agent
   โ†’ system prompt: "You handle campaigns, content, and social media strategy"
   โ†’ receives tasks assigned to marketing
   โ†’ executes them autonomously

๐Ÿ’ป Engineering Agent
   โ†’ system prompt: "You handle code reviews, deployments, and bug triage"
   โ†’ receives tasks assigned to engineering
   โ†’ executes them autonomously

๐ŸŽง Support Agent
   โ†’ system prompt: "You handle customer issues, escalations, and follow-ups"
   โ†’ receives tasks assigned to support
   โ†’ executes them autonomously
๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung ๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung

โšก The execution loop

๐Ÿ“ฅ Task assigned to agent
  โ†’ ๐Ÿค– Agent picks it up
  โ†’ โ–ถ๏ธ Executes with the task context
  โ†’ โœ… Success? Mark complete.
  โ†’ โŒ Failed?
       โ†’ ๐Ÿ”„ Retry #1 (10s delay)
       โ†’ โŒ Failed?
            โ†’ ๐Ÿ”„ Retry #2 (20s delay)
            โ†’ โŒ Failed?
                 โ†’ ๐Ÿ”„ Retry #3 (40s delay)
                 โ†’ โŒ Failed?
                      โ†’ ๐Ÿ’€ Dead letter queue
                      โ†’ ๐Ÿ”” Notify task creator
๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung ๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung

Exponential backoff. Dead letter queues. Error history tracking. This isn't a weekend project. This is production infrastructure. ๐Ÿ—๏ธ

๐Ÿ”— Agent delegation

Agent A can hand off a sub-task to Agent B:

๐Ÿค– Engineering Agent: "I need a deployment verification"
   โ†’ delegates to โ†’
๐Ÿค– DevOps Agent: "Running smoke tests..."
   โ†’ reports back โ†’
๐Ÿค– Engineering Agent: "All clear. Marking task complete."
๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung ๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung

Chain agents together for complex workflows. ๐Ÿ”—


โš™๏ธ Workflow Engine โ€” Zapier Without the Bill

Build automation rules with three components:

๐Ÿ”€ Triggers (when something happens)

  • task_created โ€” A new task is born
  • task_completed โ€” A task is done
  • task_updated โ€” Someone changed a field
  • user_registered โ€” New team member
  • schedule_daily โ€” Runs every day

๐ŸŽฏ Conditions (only if...)

  • priority == urgent
  • due_date is past
  • field contains specific text
  • status == blocked
  • A field exists

โ–ถ๏ธ Actions (then do this)

  • ๐Ÿ”” Notify a user, manager, or admin
  • ๐Ÿ“ Update task fields
  • ๐Ÿ’ฌ Send a channel message
  • โž• Create a new task

Example workflow:

Trigger: task_created
Condition: priority == urgent
Action: notify manager

Trigger: schedule_daily
Condition: due_date is past
Action: notify assigned_user + update status to "blocked"

Trigger: task_completed
Condition: department == engineering
Action: create new task "Deploy to staging" for DevOps agent
๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung ๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung

Build it once. It runs forever. No per-action billing. No premium tier. ๐Ÿ†“


๐Ÿ“ง Email That Actually Works

Not a "send notification" endpoint. Real email. ๐Ÿ“ฌ

  • ๐Ÿ“ฅ Inbox โ€” pull emails via IMAP polling
  • ๐Ÿ“ค Send โ€” SMTP outbound (Gmail, custom SMTP)
  • ๐Ÿ“ Drafts โ€” AI writes draft replies based on email context
  • โญ Star & Label โ€” organize your mail
  • ๐Ÿ” Search โ€” find anything
  • ๐Ÿ”” Notifications โ€” new email? You know instantly

The agent reads incoming emails and drafts intelligent responses. Review and send. Or let it send autonomously โ€” your call. โœ๏ธ


๐Ÿ› ๏ธ Under the Hood

Backend Architecture

server/
โ”œโ”€โ”€ src/
โ”‚   โ”œโ”€โ”€ config/
โ”‚   โ”‚   โ”œโ”€โ”€ db.js              ๐Ÿ—„๏ธ Dual SQLite/PostgreSQL adapter
โ”‚   โ”‚   โ”œโ”€โ”€ logger.js          ๐Ÿ“‹ Pino structured logging
โ”‚   โ”‚   โ””โ”€โ”€ migrate.js         ๐Ÿ”„ Versioned migrations
โ”‚   โ”œโ”€โ”€ middleware/
โ”‚   โ”‚   โ”œโ”€โ”€ auth.js            ๐Ÿ” JWT + role-based access
โ”‚   โ”‚   โ”œโ”€โ”€ rateLimit.js       ๐Ÿ›ก๏ธ Brute-force protection (login abuse)
โ”‚   โ”‚   โ””โ”€โ”€ validate.js        ๐Ÿงน Input sanitization
โ”‚   โ”œโ”€โ”€ routes/                ๐Ÿ›ฃ๏ธ 12 API modules
โ”‚   โ””โ”€โ”€ services/
โ”‚       โ”œโ”€โ”€ ai-engine.js       ๐Ÿง  LLM integration (OpenAI-compatible)
โ”‚       โ”œโ”€โ”€ email-real.js      ๐Ÿ“ง SMTP + IMAP
โ”‚       โ”œโ”€โ”€ execution-loop.js  ๐Ÿ”„ Retry + exponential backoff + DLQ
โ”‚       โ”œโ”€โ”€ scheduler.js       โฐ DB-persisted cron jobs
โ”‚       โ”œโ”€โ”€ workflows.js       โš™๏ธ Rule engine
โ”‚       โ””โ”€โ”€ notifications.js   ๐Ÿ”” Socket.IO broadcast
โ””โ”€โ”€ __tests__/                 ๐Ÿงช 58 tests (Jest + Supertest)
๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung ๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung

Frontend

web/
โ”œโ”€โ”€ app/                       ๐Ÿ“„ 12 pages (Next.js 14 App Router)
โ”œโ”€โ”€ components/                ๐Ÿงฉ Shared UI components
โ””โ”€โ”€ lib/                       ๐Ÿ”Œ API client + auth helpers
๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung ๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung

Tests โ€” Because We're Serious

Suite Tests Covers
๐Ÿ” Auth 14 Register, login, profile, password, tokens
๐Ÿ“‹ Tasks 13 CRUD, filters, comments, completion
โš™๏ธ Workflows 8 CRUD, toggle, triggers, validation
๐Ÿค– AI 11 Chat, execution, delegation, agents
๐Ÿข Departments 12 Departments, knowledge, email

58 tests. All passing. โœ…


๐Ÿ—„๏ธ Database: SQLite or PostgreSQL โ€” Your Choice

Same API. Same code. One env var difference.

# SQLite (default โ€” just works)
DB_PATH=./data/hiveops.db

# PostgreSQL (production scale)
DATABASE_URL=postgres://user:pass@host:5432/hiveops
๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung ๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung
Mode Best For
๐ŸŸข SQLite Local dev, prototyping, small teams
๐Ÿ”ต PostgreSQL Production, scale, complex queries

Switch anytime. No code changes. No migrations to redo. ๐Ÿ”„


๐Ÿง  LLM: Works With Anything OpenAI-Compatible

# OpenAI
LLM_API_URL=https://api.openai.com/v1/chat/completions
LLM_API_KEY=sk-your-key

# Ollama (local)
LLM_API_URL=http://localhost:11434/v1/chat/completions
LLM_API_KEY=ollama

# No key? No problem.
# Simulated fallback mode works out of the box.
๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung ๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung

No vendor lock-in. Run your own models locally with Ollama. Or plug in any provider. ๐Ÿ”Œ


๐Ÿ“Š The Numbers That Matter

Metric Value
๐Ÿณ Docker containers 3 (Postgres + API + Web)
โฑ๏ธ Setup time ~60 seconds
๐Ÿ“„ API routes 12 modules
๐Ÿ—„๏ธ Database tables 14
๐Ÿงช Test suite 58 tests
๐Ÿ’ฐ Cost $0 forever
๐Ÿ”’ Data location Your server

๐ŸŽฏ Who Should Use This?

  • ๐Ÿš€ Startups โ€” Can't burn $500/mo on SaaS before you have revenue
  • ๐ŸŒ Remote teams โ€” One platform instead of five disconnected tabs
  • ๐Ÿ‘ฉโ€๐Ÿ’ป Developers โ€” Self-hosted > vendor-dependent
  • ๐Ÿ—๏ธ Agencies โ€” White-label the OS for your clients
  • ๐Ÿ˜ค Anyone with SaaS fatigue โ€” Time to own your stack

๐Ÿ”ฎ What's Next?

The project is alive and growing. Here's what's on the roadmap (based on the codebase):

  • ๐Ÿ“Š More dashboard widgets
  • ๐Ÿ”Œ Additional LLM provider integrations
  • ๐Ÿ“ฑ Mobile-responsive improvements
  • ๐Ÿท๏ธ Enhanced labeling and tagging
  • ๐Ÿ“ˆ Reporting and analytics

๐Ÿ“œ Open Source. Fully. No Gimmicks.

No "open core." No "enterprise edition." No "contact sales." ๐Ÿšซ

git clone https://github.com/mamoor123/hiveops.git
๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung ๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung

โญ Star it if you like it. ๐Ÿด Fork it if you want to change it. ๐Ÿš€ Deploy it if you need it.

๐Ÿ”— github.com/mamoor123/hiveops


๐Ÿ“Œ Quick Links

Link Description
๐Ÿ“– README Full documentation
๐Ÿ› Issues Bugs & feature requests
๐Ÿงช Tests 58 tests
๐Ÿณ Docker Compose file

๐Ÿ From git clone to full company OS. One command. 60 seconds. Zero dollars.


Tags: opensource, selfhosted, ai, docker, devops, productivity, nodejs, nextjs


Related Reading

Top comments (1)

๐Ÿ† Live Soccer TV: mamoor ahmad/from git clone to full company operating system in seconds df - Jadwal Siaran Langsung
 
bta_ghost_3973f23df97163c profile image
BTA GHOST •

Thanks