bunqueue-dashboard 1.0.3 → 1.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (118) hide show
  1. package/README.md +162 -356
  2. package/dist/.vite/manifest.json +335 -608
  3. package/dist/assets/AddJob-g7DKWNZ0.js +3 -0
  4. package/dist/assets/Alerts-WcpDWdDf.js +1 -0
  5. package/dist/assets/{AreaChart-BMYp7z5y.js → AreaChart-CSP0-00u.js} +1 -1
  6. package/dist/assets/Benchmark-i6UOuIR-.js +1 -0
  7. package/dist/assets/{BulkAddJobs-0cdWqkEF.js → BulkAddJobs-56_SkYFd.js} +3 -3
  8. package/dist/assets/Cron-BnqxADsg.js +1 -0
  9. package/dist/assets/CronManager-4pAw6m87.js +1 -0
  10. package/dist/assets/Database-BDyQ8N-r.js +3 -0
  11. package/dist/assets/Diagnostics-DJNus54z.js +1 -0
  12. package/dist/assets/Dlq-BaHXmn0r.js +1 -0
  13. package/dist/assets/DlqControl-Bc48Yxxi.js +1 -0
  14. package/dist/assets/DlqPro-BaL9PRlj.js +1 -0
  15. package/dist/assets/Fleet-NYO3foQN.js +1 -0
  16. package/dist/assets/Flows-RPGep40V.js +2 -0
  17. package/dist/assets/JobInspector-DEboXZKA.js +2 -0
  18. package/dist/assets/Jobs-DRJLVzTB.js +1 -0
  19. package/dist/assets/JobsPro-BtoJgs_P.js +1 -0
  20. package/dist/assets/Logs-wZd30gMQ.js +1 -0
  21. package/dist/assets/LogsPro-Bed1atn5.js +1 -0
  22. package/dist/assets/{McpServer-ffXr4nFW.js → McpServer-CGe9T6dL.js} +2 -2
  23. package/dist/assets/Metrics-vii1CWGY.js +1 -0
  24. package/dist/assets/MetricsPro-Cbx-5-HO.js +1 -0
  25. package/dist/assets/Overview-2qju4F93.js +1 -0
  26. package/dist/assets/Pagination-ByDp7kNr.js +1 -0
  27. package/dist/assets/{QueueActions-BgdW95rN.js → QueueActions-BhjKtapT.js} +1 -1
  28. package/dist/assets/QueueControl-QMlFMQA6.js +1 -0
  29. package/dist/assets/QueueDetail-B-mcgloD.js +1 -0
  30. package/dist/assets/QueueDetailPro-BKFwiQUg.js +1 -0
  31. package/dist/assets/Queues-DCCwG__I.js +1 -0
  32. package/dist/assets/QueuesOverview-BMIfVWtk.js +1 -0
  33. package/dist/assets/S3Backup-DpLn5T8m.js +1 -0
  34. package/dist/assets/S3BackupPro-BUHJBozP.js +3 -0
  35. package/dist/assets/ServerControl-F5hvQwk3.js +3 -0
  36. package/dist/assets/Settings-UBD8Zrj0.js +1 -0
  37. package/dist/assets/{StatusBadge-cYUkK-4P.js → StatusBadge-D-mexaga.js} +1 -1
  38. package/dist/assets/Usage-D2D1i5nA.js +1 -0
  39. package/dist/assets/UsagePro-B8UDx-CC.js +1 -0
  40. package/dist/assets/Webhooks-TnNw3Mml.js +1 -0
  41. package/dist/assets/Workers-BAz4V_bk.js +1 -0
  42. package/dist/assets/WorkersPro-Cbh-P8vR.js +1 -0
  43. package/dist/assets/Workflows-CBMzJbn0.js +1 -0
  44. package/dist/assets/{api-Bbo86MB6.js → api-CCgfskjt.js} +1 -1
  45. package/dist/assets/{classicJobsData-BimIyQky.js → classicJobsData-wdIr-E4y.js} +1 -1
  46. package/dist/assets/connectionStore-B946Fhuv.js +1 -0
  47. package/dist/assets/controlConnectionEpoch-x9VjrWgN.js +1 -0
  48. package/dist/assets/{form-Dy-an7ew.js → form-DBkslwzu.js} +1 -1
  49. package/dist/assets/{icons-C1HVBnFn.js → icons-BIT5aq1c.js} +1 -1
  50. package/dist/assets/index-DR8flo6r.css +1 -0
  51. package/dist/assets/index-DcVSLtH4.js +8 -0
  52. package/dist/assets/install-Ch82YzWH.js +3 -0
  53. package/dist/assets/package-V6gqAKfV.js +1 -0
  54. package/dist/assets/react-vendor-08inPAVO.js +11 -0
  55. package/dist/assets/responses-YgpvqWEr.js +1 -0
  56. package/dist/assets/rolldown-runtime-XKyaHtl9.js +1 -0
  57. package/dist/assets/{useControlActionGuard-DImMgJtj.js → useControlActionGuard-Bx5MkufG.js} +1 -1
  58. package/dist/assets/{useServerActionGuard-Cr4KUOeZ.js → useServerActionGuard-uiZWD3dS.js} +1 -1
  59. package/dist/assets/useThroughputSeries-BZ9Bb2PU.js +1 -0
  60. package/dist/favicon.svg +11 -22
  61. package/dist/index.html +8 -16
  62. package/package.json +29 -36
  63. package/scripts/embedded.gen.ts +130 -146
  64. package/dist/assets/AddJob-jq-VZ_YE.js +0 -3
  65. package/dist/assets/Alerts-Bi8zLKXV.js +0 -1
  66. package/dist/assets/Benchmark-CWYdqm55.js +0 -1
  67. package/dist/assets/Button-BCjgbAhY.js +0 -1
  68. package/dist/assets/Card-DptfvL2O.js +0 -1
  69. package/dist/assets/Cron-dPGwJXqY.js +0 -1
  70. package/dist/assets/CronManager-C0-Y2QDg.js +0 -1
  71. package/dist/assets/Database-CseJOrvD.js +0 -3
  72. package/dist/assets/Diagnostics-cZTy4Y2t.js +0 -1
  73. package/dist/assets/Dlq-W2xOJiZM.js +0 -1
  74. package/dist/assets/DlqControl-CIV5278D.js +0 -1
  75. package/dist/assets/DlqPro-BuRxGtGt.js +0 -1
  76. package/dist/assets/Fleet-0zKJSjCw.js +0 -1
  77. package/dist/assets/Flows-CEfm102Y.js +0 -2
  78. package/dist/assets/JobInspector-BlMj5-Vr.js +0 -2
  79. package/dist/assets/Jobs-D_TId_Oa.js +0 -1
  80. package/dist/assets/JobsPro-A06ZG5Xi.js +0 -1
  81. package/dist/assets/Logs-hbh7XhQU.js +0 -1
  82. package/dist/assets/LogsPro-BgEIjgfj.js +0 -1
  83. package/dist/assets/Metrics-CIKZGgf0.js +0 -1
  84. package/dist/assets/MetricsPro-CK3WfLCl.js +0 -1
  85. package/dist/assets/Overview-BBgwyUn4.js +0 -1
  86. package/dist/assets/PageHeader-DD4vnVog.js +0 -1
  87. package/dist/assets/Pagination-Cj7GzYNX.js +0 -1
  88. package/dist/assets/QueueControl-g-9kwrpt.js +0 -1
  89. package/dist/assets/QueueDetail-Cv3MLDoE.js +0 -1
  90. package/dist/assets/QueueDetailPro-AhdOAzEF.js +0 -1
  91. package/dist/assets/Queues-Bbvh_OCE.js +0 -1
  92. package/dist/assets/QueuesOverview-sPQILfMU.js +0 -1
  93. package/dist/assets/S3Backup-Cg6sc2JG.js +0 -1
  94. package/dist/assets/S3BackupPro-BWV_R_Vj.js +0 -3
  95. package/dist/assets/ServerControl-Dr2gXbaU.js +0 -3
  96. package/dist/assets/Settings-BsDDlu-h.js +0 -1
  97. package/dist/assets/Usage-Cxx6pZfb.js +0 -1
  98. package/dist/assets/UsagePro-CkC8WYcS.js +0 -1
  99. package/dist/assets/Webhooks-BKWnALGC.js +0 -1
  100. package/dist/assets/Workers-SJ9MApx3.js +0 -1
  101. package/dist/assets/WorkersPro-BDgHBTpY.js +0 -1
  102. package/dist/assets/Workflows-Cp6jqKeM.js +0 -1
  103. package/dist/assets/bq-CSX8DSME.js +0 -1
  104. package/dist/assets/connectionStore-DdLzJyut.js +0 -1
  105. package/dist/assets/controlConnectionEpoch-D4HtriLM.js +0 -1
  106. package/dist/assets/feedback-Dxfj-Fy1.js +0 -1
  107. package/dist/assets/format-Cg7VCIZW.js +0 -1
  108. package/dist/assets/index-CxzFSZj3.js +0 -8
  109. package/dist/assets/index-DZXf58c2.css +0 -1
  110. package/dist/assets/install-DUkXE5kb.js +0 -3
  111. package/dist/assets/package-C7CtgBEy.js +0 -1
  112. package/dist/assets/react-vendor-DfC0iyIS.js +0 -11
  113. package/dist/assets/responses-BkR2JTH9.js +0 -1
  114. package/dist/assets/rolldown-runtime-QTnfLwEv.js +0 -1
  115. package/dist/assets/toastStore-DnqA_aL-.js +0 -1
  116. package/dist/assets/usePolledData-Dp_ynL9f.js +0 -1
  117. package/dist/assets/useThroughputSeries-CrTeR9s3.js +0 -1
  118. package/patches/ai@7.0.14.patch +0 -25
package/README.md CHANGED
@@ -1,397 +1,203 @@
1
- <div align="center">
2
-
3
- <img src="docs/logo.svg" alt="bunqueue dashboard" width="340" />
4
-
5
- # bunqueue dashboard
6
-
7
- **Monitor jobs and operate your Bunqueue server from one dashboard.**
8
-
9
- Manage queues, jobs, DLQ,
10
- cron, webhooks, workers, and a live activity stream for a [bunqueue](https://bunqueue.dev) server
11
- (a fast, Redis-free, Bun-native background-job queue), plus **start / stop / restart of the server
12
- process itself**, all from one place.
13
-
14
- For Bun developers and AI-agent builders running bunqueue who want to _operate_ their queue, not just watch it.
15
-
16
- ### [📚 Read the documentation](https://egeominotti.github.io/bunqueue-dashboard/docs/) · [▶ Try the live demo](https://egeominotti.github.io/bunqueue-dashboard/)
17
-
18
- [Quick start](https://egeominotti.github.io/bunqueue-dashboard/docs/quickstart) · [User guide](https://egeominotti.github.io/bunqueue-dashboard/docs/user-guide) · [Deployment](https://egeominotti.github.io/bunqueue-dashboard/docs/deploy/) · [Verified test coverage](https://egeominotti.github.io/bunqueue-dashboard/docs/testing)
19
-
20
- The live demo uses sample data. The docs explain how to connect and operate a real Bunqueue server.
21
-
22
- [![npm](https://img.shields.io/npm/v/bunqueue-dashboard?logo=npm&color=cb3837)](https://www.npmjs.com/package/bunqueue-dashboard)
23
- [![CI](https://github.com/egeominotti/bunqueue-dashboard/actions/workflows/ci.yml/badge.svg)](https://github.com/egeominotti/bunqueue-dashboard/actions/workflows/ci.yml)
24
- [![Deploy to GitHub Pages](https://github.com/egeominotti/bunqueue-dashboard/actions/workflows/pages.yml/badge.svg)](https://github.com/egeominotti/bunqueue-dashboard/actions/workflows/pages.yml)
25
- [![Docker](https://github.com/egeominotti/bunqueue-dashboard/actions/workflows/docker.yml/badge.svg)](https://github.com/egeominotti/bunqueue-dashboard/actions/workflows/docker.yml)
26
- [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
27
- [![Documentation](https://img.shields.io/badge/docs-online-db2777)](https://egeominotti.github.io/bunqueue-dashboard/docs/)
28
- [![Live demo](https://img.shields.io/badge/live%20demo-online-22c55e)](https://egeominotti.github.io/bunqueue-dashboard/)
29
- ![Status: Stable](https://img.shields.io/badge/status-stable-22c55e)
30
-
31
- ![React 19](https://img.shields.io/badge/React-19-149ECA?logo=react&logoColor=white)
32
- ![Vite 8](https://img.shields.io/badge/Vite-8-646CFF?logo=vite&logoColor=white)
33
- ![Bun](https://img.shields.io/badge/Bun-1.4-000?logo=bun&logoColor=white)
34
- ![TypeScript](https://img.shields.io/badge/TypeScript-strict-3178C6?logo=typescript&logoColor=white)
35
- ![Oxlint + Bun fmt](https://img.shields.io/badge/Tooling-Oxlint%20%2B%20Bun%20fmt-7C3AED)
36
-
37
- <br />
38
-
39
- <a href="https://www.youtube.com/watch?v=1bQRFXGClcc" title="Watch the full bunqueue dashboard tour on YouTube"><img src="docs/public/video-tour.png" alt="Watch the narrated 4K tour of bunqueue dashboard on YouTube" width="900" /></a>
40
-
41
- ### [▶ Watch the full tour on YouTube](https://www.youtube.com/watch?v=1bQRFXGClcc)
42
-
43
- <sub>A narrated 4K walkthrough (7:45, English with subtitles) recorded against a real bunqueue server under live traffic. <a href="https://egeominotti.github.io/bunqueue-dashboard/">Or try the live demo →</a></sub>
44
-
45
- <br /><br />
46
-
47
- <img src="docs/screenshots/overview.png" alt="bunqueue dashboard, real-time overview: health, throughput, per-queue status, and a live activity feed" width="900" />
48
-
49
- <sub>The Overview page. <a href="https://egeominotti.github.io/bunqueue-dashboard/docs/user-guide">See every screen in the illustrated guide →</a></sub>
50
-
51
- <details>
52
- <summary><b>More screenshots</b></summary>
53
- <br />
54
- <img src="docs/screenshots/server.png" alt="Server Control, start/stop/restart the bunqueue process with live logs" width="900" />
55
- <img src="docs/screenshots/jobs.png" alt="Jobs Explorer, filter, inspect, and bulk-action jobs" width="900" />
56
- <img src="docs/screenshots/database.png" alt="Read-only SQLite inspector, browse tables and run queries" width="900" />
57
- </details>
58
-
59
- </div>
60
-
61
- ---
62
-
63
- > ✅ **Stable (1.x).** The dashboard follows [Semantic Versioning](https://semver.org/):
64
- > breaking changes to its configuration, routes or agent API only ship in a new
65
- > major version.
66
-
67
- ## 📚 Documentation
68
-
69
- **Full, illustrated docs live at
70
- [egeominotti.github.io/bunqueue-dashboard/docs](https://egeominotti.github.io/bunqueue-dashboard/docs/).**
71
-
72
- - **[Illustrated user guide](https://egeominotti.github.io/bunqueue-dashboard/docs/user-guide)**, section guides with screenshots, operations and limitations.
73
- - **[Deployment](https://egeominotti.github.io/bunqueue-dashboard/docs/deploy/)**, Docker (Caddy), Kubernetes, PM2, and hosting platforms (Vercel, Netlify, Cloudflare, Fly.io, Render, Cloud Run).
74
- - **[Architecture](https://egeominotti.github.io/bunqueue-dashboard/docs/architecture)** and **[API mapping](https://egeominotti.github.io/bunqueue-dashboard/docs/api-mapping)**, how it fits together and every endpoint it drives.
75
- - **[Testing matrix](docs/testing.md)**, real-server coverage, reproduction steps and verification limits.
76
- - **[llms.txt](https://egeominotti.github.io/bunqueue-dashboard/docs/llms.txt)**, the documentation index for LLMs; **[llms-full.txt](https://egeominotti.github.io/bunqueue-dashboard/docs/llms-full.txt)** contains the full text.
77
-
78
- ## Table of contents
79
-
80
- - [Documentation](#-documentation)
81
- - [Why](#why)
82
- - [Features](#features)
83
- - [Quick start](#quick-start)
84
- - [Architecture](#architecture)
85
- - [Configuration](#configuration)
86
- - [Scripts](#scripts)
87
- - [Docker](#docker)
88
- - [Deployment](#deployment)
89
- - [Testing & quality gate](#testing--quality-gate)
90
- - [Project structure](#project-structure)
91
- - [Security](#security)
92
- - [Contributing](#contributing)
93
- - [License](#license)
94
-
95
- ## Why
96
-
97
- bunqueue exposes a rich HTTP API, but operating it by hand (curl, ad-hoc scripts) is slow and
98
- error-prone. This dashboard is a production-oriented operator console: it exposes the verified,
99
- safe subset of the API, fails closed where
100
- [Bunqueue 2.9.x](https://github.com/egeominotti/bunqueue/releases/tag/v2.9.3) lacks atomic
101
- flow-safety guarantees, and also manages the
102
- server *process* through a separate guarded agent.
103
-
104
- It uses Bunqueue's public HTTP API (`:6790`) for ordinary remote observability and a small local
105
- **control agent** for process, FlowProducer, Workflow Engine, database, and backup operations. The
106
- agent is pinned to the server it manages and uses the exact installable Bunqueue 2.9.4 npm client
107
- contracts; it never patches Bunqueue internals.
108
-
109
- ## Features
110
-
111
- | Area | Where | What you can do |
112
- | --- | --- | --- |
113
- | **Home** | Overview | Live health banner, throughput, queue health, recent activity |
114
- | **Fleet** | Fleet | Probe and operate multiple Bunqueue APIs + paired agents; verify shared PostgreSQL target/namespace topology |
115
- | **Server** | Control ▸ Server | **Start / stop / restart** the server process, edit its config, tail process logs |
116
- | **Enqueue** | Control ▸ Add Job | Add jobs (single or bulk) with every option |
117
- | **Inspect** | Control ▸ Job Inspector | Look up any job; promote / re-prioritize / delay; view data & result |
118
- | **Queues** | Control ▸ Queue Control | Pause/resume/promote; desired-state writes plus live SDK limits, group jobs/priorities/pause/policies, deduplication, metrics and journal retention |
119
- | **Cron** | Control ▸ Cron Manager | Submit acknowledged cron/interval upserts and delete schedules |
120
- | **Workflow Engine** | Workflow ▸ Overview / Executions / Waiting / Compensation / Archive | Start, recover, signal, inspect, compensate, archive and clean durable executions |
121
- | **Job Flows** | Workflow ▸ Job Flows | Explore DAGs, run all FlowProducer create modes and operate safe Flow Job methods |
122
- | **DLQ** | Control ▸ DLQ | Inspect/export failures; removal, retry and purge stay unavailable without atomic generation/topology preconditions |
123
- | **Webhooks** | Control ▸ Webhooks | Create / enable / delete job-event webhooks |
124
- | **Ops** | Control ▸ Diagnostics | Health, ping, storage, memory, connections, totals |
125
- | **S3 backup** | Management ▸ S3 Backup | Configure, inspect, list, create and guarded-restore official snapshots |
126
- | **Browse** | Queues / Jobs / DLQ / Cron / Metrics / Workers / Logs | Read-only browsing with basic actions |
127
-
128
- > Job actions are gated by the v2.9.3 flow contract. Every DLQ retry and completed-job requeue is
129
- > unavailable: the DLQ GET + POST sequence has no atomic generation/state/topology precondition and
130
- > can target a job recreated under the same ID, while `retryCompleted` does not rebuild dependency
131
- > registration or flow order. Cancel, Discard, Drain, Clean, Obliterate and DLQ Purge also fail
132
- > closed. Bunqueue 2.9's `Queue.removeDlqJob()` also accepts only queue + job ID, so custom-ID reuse
133
- > prevents the dashboard from proving that a later deletion still targets the observed generation.
134
- > DLQ `maxAge`/`maxEntries` are read-only, and auto-retry can only be disabled. The in-app Copilot
135
- > is switched off in official builds (`VITE_ENABLE_COPILOT=1` opts a custom build back in).
1
+ <p align="center">
2
+ <a href="https://bunqueue.dev/">
3
+ <img src="https://raw.githubusercontent.com/egeominotti/bunqueue/main/docs/src/assets/logo.svg" alt="bunqueue logo" width="88" height="88" />
4
+ </a>
5
+ </p>
6
+
7
+ <h1 align="center">bunqueue dashboard</h1>
8
+
9
+ <p align="center">
10
+ A web console for your Bunqueue jobs, workflows and servers.
11
+ </p>
12
+
13
+ <p align="center">
14
+ <a href="https://egeominotti.github.io/bunqueue-dashboard/">Live demo</a> ·
15
+ <a href="https://egeominotti.github.io/bunqueue-dashboard/docs/">Documentation</a> ·
16
+ <a href="https://github.com/egeominotti/bunqueue-dashboard/releases">Downloads</a> ·
17
+ <a href="https://www.youtube.com/watch?v=1bQRFXGClcc">Video tour</a>
18
+ </p>
19
+
20
+ <p align="center">
21
+ <a href="https://www.npmjs.com/package/bunqueue-dashboard"><img src="https://img.shields.io/npm/v/bunqueue-dashboard?color=db2777" alt="npm version" /></a>
22
+ <a href="https://github.com/egeominotti/bunqueue-dashboard/actions/workflows/ci.yml"><img src="https://github.com/egeominotti/bunqueue-dashboard/actions/workflows/ci.yml/badge.svg" alt="CI" /></a>
23
+ <a href="https://bun.com/"><img src="https://img.shields.io/badge/Bun-1.4.4-14151a?logo=bun&logoColor=white" alt="Bun 1.4.4" /></a>
24
+ <a href="LICENSE"><img src="https://img.shields.io/badge/license-MIT-blue" alt="MIT license" /></a>
25
+ </p>
26
+
27
+ Monitor and operate [Bunqueue](https://bunqueue.dev/) from your browser: find jobs,
28
+ inspect failures, manage schedules, follow durable workflows and control the server
29
+ process. Connect to one broker or keep several broker/agent profiles in Settings.
30
+
31
+ The dashboard targets **Bunqueue 2.9.20**. The live demo uses sample data; the
32
+ published package connects to your own server.
136
33
 
137
34
  ## Quick start
138
35
 
139
- **Prerequisites:** [Bun](https://bun.sh) 1.4.4 and a reachable bunqueue server (or let the control
140
- agent start one for you from the **Server** page).
141
-
142
- ### Run from npm (no clone)
36
+ Install [Bun 1.4.4](https://bun.com/docs/installation), then run:
143
37
 
144
38
  ```bash
145
39
  bunx bunqueue-dashboard
146
40
  ```
147
41
 
148
- One command serves the prebuilt dashboard on
149
- http://127.0.0.1:8080, proxies `/api/*` to your bunqueue server (`BUNQUEUE_URL`, default
150
- `http://localhost:6790`), and runs the control agent on `127.0.0.1:6800`. Same env knobs as the
151
- standalone binaries: `PORT` · `BIND_ADDR` · `BUNQUEUE_URL` · `AGENT_PORT` ·
152
- `AGENT_ALLOWED_ORIGINS` · `AGENT_ALLOWED_HOSTS` · `AGENT_TOKEN` · `BUNQUEUE_TOKEN` ·
153
- `TRUST_PROXY` · `BASE_PATH` · `BUNQUEUE_MANAGED` · `BUNQUEUE_START_CMD`.
154
-
155
- Install it permanently instead of running via `bunx`:
42
+ Open **[http://127.0.0.1:8080](http://127.0.0.1:8080)**.
156
43
 
157
- ```bash
158
- bun add -g bunqueue-dashboard
159
- bunqueue-dashboard
160
- ```
44
+ - To start a local Bunqueue server, open **Server** and select **Start**. The
45
+ default command runs the compatible Bunqueue 2.9.20 release.
46
+ - To connect an existing server, configure its API URL and token in **Settings**.
47
+ For a broker managed by another supervisor, use the command below.
161
48
 
162
- ### Run from source
49
+ The npm package serves the built UI, proxies API requests and includes the local
50
+ control agent. Its default agent address is `http://127.0.0.1:6800`.
163
51
 
164
- ```bash
165
- git clone https://github.com/egeominotti/bunqueue-dashboard.git
166
- cd bunqueue-dashboard
167
- bun install
168
- bun start
169
- ```
52
+ <p align="center">
53
+ <img src="https://raw.githubusercontent.com/egeominotti/bunqueue-dashboard/main/docs/screenshots/overview.png" alt="Dashboard overview with server health, job counts, throughput and queue activity" width="1000" />
54
+ </p>
170
55
 
171
- `bun start` boots **both** the control agent and the dashboard in one terminal and shuts both down
172
- on `Ctrl-C`:
56
+ ## What you can do
173
57
 
174
- | Service | URL | Role |
175
- | --- | --- | --- |
176
- | Dashboard | http://localhost:5273 | The UI (`/api/*` is proxied to `:6790` in dev) |
177
- | Control agent | http://127.0.0.1:6800 | Starts / stops / restarts the server process |
178
- | bunqueue server | http://localhost:6790 | Your queue server, started from the **Server** page or run separately |
179
-
180
- Prefer separate terminals? The individual commands still exist, see [Scripts](#scripts).
181
-
182
- ## Architecture
183
-
184
- ```mermaid
185
- flowchart LR
186
- subgraph Browser
187
- UI["Dashboard (React 19 SPA)"]
188
- end
189
- subgraph Local
190
- Agent["Control agent (Bun)<br/>127.0.0.1:6800"]
191
- Server["bunqueue server<br/>:6790 HTTP · :6789 TCP"]
192
- end
193
- UI -- "HTTP: queues, jobs, DLQ, cron…" --> Server
194
- UI -- "SSE: live activity" --> Server
195
- UI -- "/control/* start·stop·restart" --> Agent
196
- Agent -- "spawn / kill process" --> Server
197
- ```
198
-
199
- - **Reads** by polling (`usePolledData`) and a Server-Sent Events stream (`useActivityStream`).
200
- - **Writes** through the same HTTP API, with every mutation shape-verified against the live server.
201
- - **Managed operations** use the local control agent for process lifecycle, Queue SDK controls,
202
- FlowProducer, Workflow Engine, SQLite inspection, and backups.
58
+ | Area | Capabilities |
59
+ | --- | --- |
60
+ | Jobs | Submit single or bulk jobs, inspect data and results, change eligible jobs, and export the complete filtered inventory to CSV. |
61
+ | Queues and schedules | Browse queue state, pause and resume processing, configure limits and groups, and manage cron or interval schedules. |
62
+ | Workflows and flows | Start and inspect durable executions, send signals, recover or compensate workflows, and explore dependency graphs. |
63
+ | Monitoring | Follow live events, inspect metrics and diagnostics, search workers, and evaluate alert rules. |
64
+ | Fleet | Save multiple broker/agent profiles and inspect shared PostgreSQL topology while keeping each node's lifecycle controls separate. |
65
+ | Server control | Start, stop and restart a managed Bunqueue process, edit its launch settings, and read its logs. |
66
+ | Data and backups | Browse SQLite tables, run read-only SQL, export rows, and create or restore official S3 snapshots. |
67
+ | MCP | Browse Bunqueue's tool catalog and configure external MCP clients. |
203
68
 
204
- For multiple brokers, create one named Dashboard profile and one paired control
205
- agent per broker. The Fleet page probes all profiles without retargeting the
206
- active UI, groups brokers that share an exact PostgreSQL target + namespace,
207
- and drives each node's Start/Stop/Restart controls. Queue state is shared by
208
- PostgreSQL; lifecycle, process logs/config, in-memory webhooks, and each agent's
209
- Workflow Engine store remain node-local. See the
210
- [Fleet guide](https://egeominotti.github.io/bunqueue-dashboard/docs/guide/fleet).
69
+ SQLite inspection and S3 snapshots apply to SQLite-backed servers. PostgreSQL
70
+ profiles use the queue and fleet controls.
211
71
 
212
- Two HTTP clients coexist on purpose: `src/lib/api.ts` (first-generation view pages) and
213
- `src/lib/bq.ts` (the complete, shape-verified client used by every `Control ▸ *` page). See
214
- [`docs/`](docs/README.md) for the full, source-verified reference.
72
+ Job actions follow Bunqueue's safety contracts. Operations without atomic job
73
+ identity or flow-topology safeguards remain disabled, including DLQ retry,
74
+ completed-job requeue, cancel, drain and purge. See the
75
+ [verified limitations](https://egeominotti.github.io/bunqueue-dashboard/docs/known-issues).
215
76
 
216
- ## Configuration
77
+ An optional [Copilot](https://egeominotti.github.io/bunqueue-dashboard/docs/guide/copilot)
78
+ supports AI-assisted operations in custom builds with `VITE_ENABLE_COPILOT=1`.
79
+ It is disabled in the default build.
217
80
 
218
- The `VITE_*` dashboard defaults are build-time values and can **also** seed the first named profile
219
- in **Settings**. Add up to 32 broker/agent profiles at runtime. The all-in-one server reads the non-`VITE_*` runtime variables below.
220
- Copy [`.env.example`](.env.example) to `.env` to set defaults.
81
+ ## Connect an existing server
221
82
 
222
- | Variable | Purpose | Default |
223
- | --- | --- | --- |
224
- | `VITE_BUNQUEUE_URL` | bunqueue server origin | `/api` (dev proxy → `:6790`) |
225
- | `VITE_BUNQUEUE_AGENT_URL` | Control-agent origin | `http://localhost:6800` |
226
- | `BIND_ADDR` | All-in-one dashboard bind address | `127.0.0.1` |
227
- | `BASE_PATH` | Runtime mount for the all-in-one server (for example `/internal/queue`) | `/` |
228
- | `BUNQUEUE_MANAGED` | `0` attaches to the externally supervised `BUNQUEUE_URL`; `1` enables local lifecycle controls | `1` |
229
- | `AGENT_PORT` | Control-agent port | `6800` |
230
- | `AGENT_ALLOWED_ORIGINS` | Extra browser origins allowed to drive the agent (comma-separated) | dev defaults |
231
- | `AGENT_ALLOWED_HOSTS` | Extra Host names/IPs accepted by the all-in-one server and agent | loopback names |
232
- | `AGENT_TOKEN` | Agent bearer token; mandatory on every bridged route for LAN/proxy access | _none_ (local-only) |
233
- | `BUNQUEUE_TOKEN` | Admin-API bearer; mandatory on every `/api/*` route for LAN/proxy access | _none_ (`/api` remote-disabled) |
234
- | `TRUST_PROXY` | Trust an overwritten `X-Forwarded-Host` from a Host-rewriting proxy (`1`) | _off_ |
235
-
236
- Server and agent bearer tokens are secrets: enter them in **Settings** or the
237
- authentication prompt for the current browser session. Do not put secrets in a
238
- `VITE_*` variable; Vite values are compiled as plaintext into the public bundle.
239
-
240
- For `BIND_ADDR=0.0.0.0`, list every LAN hostname/IP in
241
- `AGENT_ALLOWED_HOSTS` (or its full origin in `AGENT_ALLOWED_ORIGINS`) and set
242
- both `AGENT_TOKEN` and `BUNQUEUE_TOKEN`. Enter `BUNQUEUE_TOKEN` as the Server
243
- token in Settings; when Bunqueue itself uses `AUTH_TOKENS`, use the same token
244
- there so the forwarded Authorization header is valid upstream. Behind a reverse
245
- proxy, allowlist the public origin; if it rewrites `Host`, also allowlist the
246
- rewritten Host and use `TRUST_PROXY=1` only when the proxy overwrites
247
- `X-Forwarded-Host`.
248
-
249
- For a broker already owned by systemd, Docker or Kubernetes, run the all-in-one
250
- dashboard with `BUNQUEUE_MANAGED=0`. **Control ▸ Server** then reports health
251
- from `BUNQUEUE_URL` and cannot spawn, stop, restart or reconfigure a child.
252
- Stopped-only backup restore is also rejected because the dashboard cannot prove
253
- that an externally supervised broker is inactive.
254
- To mount the same process below a reverse-proxy prefix, set for example
255
- `BASE_PATH=/internal/queue` and preserve that prefix when proxying; the SPA,
256
- assets, `/api` proxy and `/agent` bridge all move below it, including the
257
- target-pinned Flow, Workflow, Queue and Backup agent operations.
258
-
259
- ## Scripts
260
-
261
- | Command | Does |
262
- | --- | --- |
263
- | `bun start` | **Agent + dashboard together** (one-command dev) |
264
- | `bun dev` | Dashboard only (Vite dev server) |
265
- | `bun run agent` | Control agent only |
266
- | `bun run build` | Native Bun typecheck + production build → `dist/` |
267
- | `bun run typecheck` | Native `bun check` for the frontend, agent/scripts, examples and browser tests |
268
- | `bun run preview` | Preview the production build |
269
- | `bun run lint` | Lint with Oxlint, including type-aware rules and the implicit-`any` parity guard |
270
- | `bun run format:check` | Check formatting with native `bun fmt --check` |
271
- | `bun run check` | Native typechecking, Oxlint and native formatting validation |
272
- | `bun run check:fix` | Apply safe Oxlint fixes, then format with native `bun fmt` |
273
- | `bun test` | Unit + agent-lifecycle tests |
274
- | `bun run test:e2e:tls` | Queue, Flow and Workflow over verified native TLS, including untrusted-certificate rejection |
275
- | `bun run test:e2e:upgrade` | Real npm Bunqueue 2.9.2 SQLite schema-35 → 2.9.20 schema-37 migration and retention semantics |
276
- | `bun run test:e2e` | Real TLS, SQLite upgrade, Flow, Workflow, Queue SDK, and three-broker PostgreSQL runtime tests |
277
- | `bun run test:e2e:browser` | Production UI tests on Chromium, Firefox and WebKit |
278
- | `bun run test:e2e:browser:postgres-fleet` | Real UI operations across three PostgreSQL brokers (requires Docker and Chromium) |
279
- | `bun run quality` | Complete static, build, docs, coverage, runtime, package and dependency gate |
280
- | `bun run test:e2e:postgres-fleet` | Three authenticated Bunqueue 2.9.20 brokers + three agents sharing disposable PostgreSQL 18.6 |
281
-
282
- ## Docker
283
-
284
- A multi-stage image builds the SPA with Bun and serves it with Caddy (gzip/zstd, SPA history fallback, immutable asset caching). Published to the GitHub Container Registry on every push.
83
+ When Docker, Kubernetes or systemd owns your Bunqueue process, launch the dashboard
84
+ in external-server mode:
285
85
 
286
86
  ```bash
287
- # Pull & run the published image (`edge` tracks main; use `vX.Y.Z`/`latest` after a release)
288
- docker run --rm -p 8080:80 ghcr.io/egeominotti/bunqueue-dashboard:edge
289
- # → http://localhost:8080 (set the server URL from the Settings page)
290
-
291
- # …or build locally, optionally baking in a default server origin
292
- docker build --build-arg VITE_BUNQUEUE_URL=https://queue.example.com -t bunqueue-dashboard .
293
- docker run --rm -p 8080:80 bunqueue-dashboard
87
+ BUNQUEUE_MANAGED=0 \
88
+ BUNQUEUE_URL=http://127.0.0.1:6790 \
89
+ bunx bunqueue-dashboard
294
90
  ```
295
91
 
296
- Tags: `latest` and `vX.Y.Z` on releases, `edge` on `main`.
92
+ This mode reports the server's health and keeps process management with its
93
+ existing supervisor. Stopped-only backup restore is also unavailable in this mode.
297
94
 
298
- ## Deployment
95
+ For an authenticated broker, set `BUNQUEUE_TOKEN` in the dashboard launch
96
+ environment and enter the matching server token in Settings. The launch value
97
+ also authenticates the agent's health probe. Pair an agent with the same broker
98
+ for SDK, workflow, database and backup operations. See
99
+ [connection and deployment options](https://egeominotti.github.io/bunqueue-dashboard/docs/deploy/).
299
100
 
300
- - **Standalone executables**, every [release](https://github.com/egeominotti/bunqueue-dashboard/releases)
301
- ships self-contained binaries for **Linux (x64/arm64), macOS (x64/arm64) and Windows (x64)**:
302
- download one file and run it, it serves the dashboard (assets embedded), proxies `/api` to your
303
- bunqueue server (`BUNQUEUE_URL`, default `:6790`) and includes the control agent.
304
- ```bash
305
- ./bunqueue-dashboard-vX.Y.Z-darwin-arm64 # → http://localhost:8080
306
- PORT=3000 BUNQUEUE_URL=https://queue.example.com ./bunqueue-dashboard-vX.Y.Z-linux-x64
307
- ```
308
- - **GitHub Pages**, every push to `main` builds and publishes the static SPA
309
- (`.github/workflows/pages.yml`). The workflow **attempts** to auto-provision Pages; if the first
310
- run reports `Get Pages site failed`, enable it once under **Settings ▸ Pages ▸ Source → GitHub
311
- Actions** (the default `GITHUB_TOKEN` can't create a Pages site on its own). The build sets the
312
- correct sub-path base and a `404.html` SPA fallback automatically.
313
- - **Container**, self-host the published `ghcr.io` image behind any reverse proxy.
314
- - **Static host**, `bun run build` emits a plain `dist/` you can serve from any CDN or static host.
101
+ ## Deployment options
315
102
 
316
- Because the deployed build is a static shell, point it at a reachable bunqueue server via
317
- `VITE_BUNQUEUE_URL` (build time) or the **Settings** page (runtime).
103
+ | Option | What it runs | Requirements |
104
+ | --- | --- | --- |
105
+ | `bunx bunqueue-dashboard` | UI, API proxy and control agent | Bun 1.4.4 |
106
+ | [Standalone executable](https://github.com/egeominotti/bunqueue-dashboard/releases/latest) | UI, API proxy and control agent in one binary | Linux or macOS x64/arm64, or Windows x64 |
107
+ | [Docker image](https://egeominotti.github.io/bunqueue-dashboard/docs/deploy/docker) | Static UI served by Caddy | An existing Bunqueue API and any paired agents |
108
+ | [Static hosting](https://egeominotti.github.io/bunqueue-dashboard/docs/deploy/platforms) | Built `dist/` directory | A reachable API or a configured same-origin proxy |
318
109
 
319
- ## Testing & quality gate
110
+ The standalone dashboard executable runs without an installed Bun runtime.
111
+ Starting a managed Bunqueue process still requires its launch command to be
112
+ available: install Bun for the default `bunx` command, or configure
113
+ `BUNQUEUE_START_CMD` to use a Bunqueue executable.
320
114
 
321
- Use both the canonical gate and browser tests to validate a change. Browser tests are a separate
322
- CI job; `quality` alone does not run Playwright:
115
+ To run the published static image locally:
323
116
 
324
117
  ```bash
325
- bun run test:e2e:browser:install # first run only
326
- bun run quality # includes runtime E2E; requires Docker
327
- bun run test:e2e:browser # production UI on all three browser engines
328
- bun run test:e2e:browser:postgres-fleet # cross-node UI; separate from both commands above
118
+ docker run --rm \
119
+ -p 127.0.0.1:8080:80 \
120
+ ghcr.io/egeominotti/bunqueue-dashboard:edge
329
121
  ```
330
122
 
331
- The E2E stage starts disposable Bunqueue 2.9.4 processes and exercises the complete FlowProducer,
332
- Workflow Engine, and Queue SDK operator bridges. It also starts PostgreSQL 18.6 in Docker with
333
- three authenticated brokers and paired agents, proving cross-broker enqueue/inspect/leased
334
- pull+ack, pause/resume, cron, rate limits, group admission, group priority and group pause/resume
335
- on PostgreSQL schema 20. Run it alone with `bun run test:e2e` (Docker is required for the
336
- PostgreSQL stage).
337
-
338
- The blocking browser job builds the production bundle under `/e2e/dashboard`, starts an
339
- authenticated disposable Bunqueue server, and drives the UI with Playwright on Chromium, Firefox,
340
- and WebKit. It covers the token gate, every sidebar route, SSE recovery across a real server
341
- restart, confirmed Cron creation/deletion, job submission and bulk import, persisted job inspection,
342
- DLQ failures, live monitoring and alerts, SQLite queries, webhook registry mutations, a real
343
- producer/worker benchmark, and automated WCAG A/AA checks. Install the browser
344
- binaries once with `bun run test:e2e:browser:install`, then run `bun run test:e2e:browser`.
123
+ Open `http://127.0.0.1:8080` and set the browser-reachable server URL in Settings.
124
+ The `edge` image follows `main`. The
125
+ [Docker guide](https://egeominotti.github.io/bunqueue-dashboard/docs/deploy/docker)
126
+ explains API proxying, CORS and connecting a separately running agent.
345
127
 
346
- See the [section-by-section validation matrix](docs/testing.md) for reproducible commands,
347
- prerequisites, and the distinction between live operations, navigation checks, and external
348
- integrations that need their own environment. The live demo uses sample data and is not test evidence.
128
+ ## Configuration
349
129
 
350
- CI enforces the quality gate and browser matrix on every push and pull request. See [Contributing](#contributing).
130
+ These variables configure the npm package and standalone executable:
351
131
 
352
- ## Project structure
132
+ | Variable | Purpose | Default |
133
+ | --- | --- | --- |
134
+ | `PORT` | Dashboard listener | `8080` |
135
+ | `BIND_ADDR` | Dashboard bind address | `127.0.0.1` |
136
+ | `BUNQUEUE_URL` | Bunqueue HTTP API to proxy | `http://localhost:6790` |
137
+ | `BUNQUEUE_MANAGED` | Enable local process management; use `0` for an external server | `1` |
138
+ | `AGENT_PORT` | Direct loopback control-agent port | `6800` |
139
+ | `BASE_PATH` | URL prefix for the UI, assets and API/agent bridges | `/` |
140
+ | `BUNQUEUE_DATA_PATH` | Managed server's SQLite database | `./data/bunq.db` |
141
+ | `AGENT_CONFIG_PATH` | Persistent agent configuration | `./.bunqueue-dashboard/config.json` |
142
+
143
+ For LAN or reverse-proxy access, configure `AGENT_TOKEN` and `BUNQUEUE_TOKEN`
144
+ together with an explicit host/origin allowlist through `AGENT_ALLOWED_HOSTS`
145
+ and `AGENT_ALLOWED_ORIGINS`. Enter the corresponding tokens in the dashboard's
146
+ authentication prompt or Settings. See
147
+ [the deployment security setup](https://egeominotti.github.io/bunqueue-dashboard/docs/deploy/pm2#configure-it)
148
+ for the complete proxy and token configuration.
149
+
150
+ Static builds use `VITE_BUNQUEUE_URL` and `VITE_BUNQUEUE_AGENT_URL` as initial
151
+ connection defaults; Settings can override them. `VITE_*` values are public bundle
152
+ content, so keep credentials out of them. More options, including PostgreSQL and
153
+ TLS, are documented in [`.env.example`](.env.example) and the
154
+ [agent reference](https://egeominotti.github.io/bunqueue-dashboard/docs/agent).
155
+
156
+ ## Development
157
+
158
+ Use the Bun version in [`.bun-version`](.bun-version):
353
159
 
160
+ ```bash
161
+ git clone https://github.com/egeominotti/bunqueue-dashboard.git
162
+ cd bunqueue-dashboard
163
+ bun install --frozen-lockfile
164
+ bun start
354
165
  ```
355
- bunqueue-dashboard/
356
- ├── .github/workflows/ # CI, Pages deploy, Docker publish, Release
357
- ├── agent/ # guarded process, Flow, Workflow, Queue, database and backup adapters
358
- ├── docker/ # Caddyfile for the container image
359
- ├── docs/ # source-verified reference (architecture, pages, API mapping, known issues)
360
- ├── scripts/dev.ts # one-command dev launcher (`bun start`)
361
- ├── src/
362
- │ ├── lib/ # api.ts, bq.ts, hooks, formatters, job-action gating
363
- │ ├── components/ # layout shell, UI kit, Zustand stores
364
- │ ├── features/ # feature slices with domain, application, infrastructure and UI layers
365
- │ └── pages/ # view pages + Control ▸ * operator pages
366
- └── test/ # unit, contract, UI race, agent lifecycle and integration tests
367
- ```
368
-
369
- Full walkthrough in [`docs/README.md`](docs/README.md).
370
-
371
- ## Security
372
-
373
- The control agent can spawn processes, so it is hardened by design (`agent/server.ts`):
374
166
 
375
- - Binds **`127.0.0.1` only**.
376
- - **CORS locked to an allowlist**, `Access-Control-Allow-Origin` is never `*`.
377
- - Requests carrying a **disallowed `Origin` are rejected (403)** before reaching the process manager, blocking drive-by CSRF from a malicious tab.
378
- - A **Host allowlist** blocks DNS-rebinding requests and fails closed for unknown names.
379
- - Truly local agent reads stay zero-configuration; any LAN/proxied `/agent` bridge requires **`AGENT_TOKEN` on every route**.
380
- - The all-in-one server requires **`BUNQUEUE_TOKEN` on every LAN/proxied `/api/*` route**; without it the API proxy returns `403` before contacting Bunqueue.
381
- - Embedded and Docker responses deny framing, MIME sniffing and referrer leakage.
167
+ The development dashboard runs at `http://localhost:5273`; the control agent runs
168
+ at `http://127.0.0.1:6800`. `Ctrl+C` stops both.
382
169
 
383
- Keep the direct agent port on loopback. Static/Caddy deployments that expose Bunqueue directly must
384
- still use Bunqueue `AUTH_TOKENS` or front-proxy authentication; the all-in-one `BUNQUEUE_TOKEN`
385
- boundary applies only to `scripts/serve.ts`. Host/Origin checks are not user authentication. See
386
- [`docs/known-issues.md`](docs/known-issues.md) for the honest, verified limitations.
387
-
388
- ## Contributing
389
-
390
- 1. Keep it **additive**, prefer new files + minimal glue over rewriting existing ones
391
- (see [`CLAUDE.md`](CLAUDE.md)).
392
- 2. Make the [gate](#testing--quality-gate) green: `bun run quality`.
393
- 3. Open a PR, the template walks you through the checklist. CI must pass.
170
+ | Command | Purpose |
171
+ | --- | --- |
172
+ | `bun run build` | Typecheck all projects and build the production UI |
173
+ | `bun run check` | Native Bun typechecking, Oxlint and formatting checks |
174
+ | `bun run check:fix` | Apply lint fixes and format with native `bun fmt` |
175
+ | `bun run test:coverage` | Run unit tests and enforce coverage floors |
176
+ | `bun run test:e2e:browser` | Test the production UI in Chromium, Firefox and WebKit |
177
+ | `bun run docs:build` | Build the documentation and check its links |
178
+ | `bun run quality` | Run the static, unit, real-server, package and resilience gates |
179
+
180
+ Install browser binaries once with `bun run test:e2e:browser:install`. PostgreSQL
181
+ and S3 integration tests require Docker. CI also runs the managed browser suite
182
+ and executes native binaries on all five supported platforms.
183
+
184
+ For setup details and contribution guidance, see
185
+ [Development](https://egeominotti.github.io/bunqueue-dashboard/docs/development)
186
+ and [Testing](https://egeominotti.github.io/bunqueue-dashboard/docs/testing).
187
+
188
+ ## Documentation
189
+
190
+ - [Quickstart](https://egeominotti.github.io/bunqueue-dashboard/docs/quickstart) — installation and first connection.
191
+ - [User guide](https://egeominotti.github.io/bunqueue-dashboard/docs/user-guide) — every screen and its operations.
192
+ - [Deployment](https://egeominotti.github.io/bunqueue-dashboard/docs/deploy/) — Docker, Kubernetes, PM2 and hosting platforms.
193
+ - [Architecture](https://egeominotti.github.io/bunqueue-dashboard/docs/architecture) — HTTP, SSE, agents and storage boundaries.
194
+ - [API mapping](https://egeominotti.github.io/bunqueue-dashboard/docs/api-mapping) — endpoints, payloads and action contracts.
195
+ - [Known limitations](https://egeominotti.github.io/bunqueue-dashboard/docs/known-issues) — verified upstream constraints and current behavior.
196
+ - [LLM documentation](https://egeominotti.github.io/bunqueue-dashboard/docs/llms.txt) — documentation index for AI tools, with a [full-text version](https://egeominotti.github.io/bunqueue-dashboard/docs/llms-full.txt).
394
197
 
395
198
  ## License
396
199
 
397
- [MIT](LICENSE) © Egeo Minotti
200
+ [MIT](LICENSE) © Egeo Minotti.
201
+
202
+ The Bunqueue logo is the original asset from
203
+ [egeominotti/bunqueue](https://github.com/egeominotti/bunqueue/blob/main/docs/src/assets/logo.svg).