@gravito/zenith 1.1.2 → 1.1.6
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.
- package/README.md +95 -22
- package/README.zh-TW.md +88 -0
- package/dist/bin.js +54699 -39316
- package/dist/client/assets/index-C80c1frR.css +1 -0
- package/dist/client/assets/index-CrWem9u3.js +434 -0
- package/dist/client/index.html +2 -2
- package/dist/server/index.js +54699 -39316
- package/package.json +20 -9
- package/CHANGELOG.md +0 -47
- package/Dockerfile +0 -46
- package/Dockerfile.demo-worker +0 -29
- package/ECOSYSTEM_EXPANSION_RFC.md +0 -130
- package/bin/flux-console.ts +0 -2
- package/dist/client/assets/index-BSMp8oq_.js +0 -436
- package/dist/client/assets/index-BwxlHx-_.css +0 -1
- package/docker-compose.yml +0 -40
- package/docs/ALERTING_GUIDE.md +0 -71
- package/docs/DEPLOYMENT.md +0 -157
- package/docs/DOCS_INTERNAL.md +0 -73
- package/docs/LARAVEL_ZENITH_ROADMAP.md +0 -109
- package/docs/QUASAR_MASTER_PLAN.md +0 -140
- package/docs/QUICK_TEST_GUIDE.md +0 -72
- package/docs/ROADMAP.md +0 -85
- package/docs/integrations/LARAVEL.md +0 -207
- package/postcss.config.js +0 -6
- package/scripts/debug_redis_keys.ts +0 -24
- package/scripts/flood-logs.ts +0 -21
- package/scripts/seed.ts +0 -213
- package/scripts/verify-throttle.ts +0 -49
- package/scripts/worker.ts +0 -124
- package/specs/PULSE_SPEC.md +0 -86
- package/src/bin.ts +0 -6
- package/src/client/App.tsx +0 -72
- package/src/client/Layout.tsx +0 -672
- package/src/client/Sidebar.tsx +0 -112
- package/src/client/ThroughputChart.tsx +0 -144
- package/src/client/WorkerStatus.tsx +0 -226
- package/src/client/components/BrandIcons.tsx +0 -168
- package/src/client/components/ConfirmDialog.tsx +0 -126
- package/src/client/components/JobInspector.tsx +0 -554
- package/src/client/components/LogArchiveModal.tsx +0 -432
- package/src/client/components/NotificationBell.tsx +0 -212
- package/src/client/components/PageHeader.tsx +0 -47
- package/src/client/components/Toaster.tsx +0 -90
- package/src/client/components/UserProfileDropdown.tsx +0 -186
- package/src/client/contexts/AuthContext.tsx +0 -105
- package/src/client/contexts/NotificationContext.tsx +0 -128
- package/src/client/index.css +0 -174
- package/src/client/index.html +0 -12
- package/src/client/main.tsx +0 -15
- package/src/client/pages/LoginPage.tsx +0 -162
- package/src/client/pages/MetricsPage.tsx +0 -417
- package/src/client/pages/OverviewPage.tsx +0 -517
- package/src/client/pages/PulsePage.tsx +0 -488
- package/src/client/pages/QueuesPage.tsx +0 -379
- package/src/client/pages/SchedulesPage.tsx +0 -540
- package/src/client/pages/SettingsPage.tsx +0 -1020
- package/src/client/pages/WorkersPage.tsx +0 -394
- package/src/client/pages/index.ts +0 -8
- package/src/client/utils.ts +0 -15
- package/src/server/config/ServerConfigManager.ts +0 -90
- package/src/server/index.ts +0 -860
- package/src/server/middleware/auth.ts +0 -127
- package/src/server/services/AlertService.ts +0 -321
- package/src/server/services/CommandService.ts +0 -137
- package/src/server/services/LogStreamProcessor.ts +0 -93
- package/src/server/services/MaintenanceScheduler.ts +0 -78
- package/src/server/services/PulseService.ts +0 -91
- package/src/server/services/QueueMetricsCollector.ts +0 -138
- package/src/server/services/QueueService.ts +0 -631
- package/src/shared/types.ts +0 -198
- package/tailwind.config.js +0 -73
- package/tests/placeholder.test.ts +0 -7
- package/tsconfig.json +0 -38
- package/tsconfig.node.json +0 -12
- package/vite.config.ts +0 -27
package/src/client/index.css
DELETED
|
@@ -1,174 +0,0 @@
|
|
|
1
|
-
@tailwind base;
|
|
2
|
-
@tailwind components;
|
|
3
|
-
@tailwind utilities;
|
|
4
|
-
|
|
5
|
-
@layer base {
|
|
6
|
-
:root {
|
|
7
|
-
--background: 0 0% 100%;
|
|
8
|
-
--foreground: 224 71.4% 4.1%;
|
|
9
|
-
--card: 0 0% 100%;
|
|
10
|
-
--card-foreground: 224 71.4% 4.1%;
|
|
11
|
-
--popover: 0 0% 100%;
|
|
12
|
-
--popover-foreground: 224 71.4% 4.1%;
|
|
13
|
-
--primary: 238.7 83.5% 66.7%;
|
|
14
|
-
/* Indigo 500 */
|
|
15
|
-
--primary-foreground: 210 20% 98%;
|
|
16
|
-
--secondary: 220 14.3% 95.9%;
|
|
17
|
-
--secondary-foreground: 238.7 83.5% 66.7%;
|
|
18
|
-
--muted: 220 14.3% 95.9%;
|
|
19
|
-
--muted-foreground: 220 8.9% 46.1%;
|
|
20
|
-
--accent: 220 14.3% 95.9%;
|
|
21
|
-
--accent-foreground: 238.7 83.5% 66.7%;
|
|
22
|
-
--destructive: 0 84.2% 60.2%;
|
|
23
|
-
--destructive-foreground: 210 20% 98%;
|
|
24
|
-
--border: 220 13% 91%;
|
|
25
|
-
--input: 220 13% 91%;
|
|
26
|
-
--ring: 238.7 83.5% 66.7%;
|
|
27
|
-
--radius: 1rem;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
.dark {
|
|
31
|
-
--background: 222 47% 2%;
|
|
32
|
-
--foreground: 213 31% 91%;
|
|
33
|
-
--card: 222 47% 6%;
|
|
34
|
-
--card-foreground: 213 31% 91%;
|
|
35
|
-
--popover: 222 47% 4%;
|
|
36
|
-
--popover-foreground: 213 31% 91%;
|
|
37
|
-
--primary: 238.7 83.5% 66.7%;
|
|
38
|
-
--primary-foreground: 222 47% 4%;
|
|
39
|
-
--secondary: 222 47% 10%;
|
|
40
|
-
--secondary-foreground: 213 31% 91%;
|
|
41
|
-
--muted: 222 47% 8%;
|
|
42
|
-
--muted-foreground: 215.4 16.3% 56.9%;
|
|
43
|
-
--accent: 222 47% 12%;
|
|
44
|
-
--accent-foreground: 213 31% 91%;
|
|
45
|
-
--destructive: 0 62.8% 30.6%;
|
|
46
|
-
--destructive-foreground: 210 20% 98%;
|
|
47
|
-
--border: 222 47% 14%;
|
|
48
|
-
--input: 222 47% 12%;
|
|
49
|
-
--ring: 238.7 83.5% 66.7%;
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
@layer base {
|
|
54
|
-
* {
|
|
55
|
-
@apply border-border;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
body {
|
|
59
|
-
@apply bg-background text-foreground antialiased;
|
|
60
|
-
font-feature-settings: "ss01", "ss02", "cv01", "cv02", "cv03";
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
.dark body {
|
|
64
|
-
background-image: radial-gradient(at 50% 0%, hsla(238, 83%, 66%, 0.05) 0%, transparent 50%),
|
|
65
|
-
radial-gradient(at 100% 100%, hsla(238, 83%, 66%, 0.02) 0%, transparent 50%);
|
|
66
|
-
background-attachment: fixed;
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
@layer utilities {
|
|
71
|
-
.scrollbar-thin::-webkit-scrollbar {
|
|
72
|
-
width: 6px;
|
|
73
|
-
height: 6px;
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
.scrollbar-thin::-webkit-scrollbar-track {
|
|
77
|
-
background: transparent;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
.scrollbar-thin::-webkit-scrollbar-thumb {
|
|
81
|
-
@apply bg-muted-foreground/20 rounded-full hover:bg-muted-foreground/40 transition-colors;
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
.glass {
|
|
85
|
-
@apply bg-card/60 backdrop-blur-xl border-white/10;
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
.scanline {
|
|
89
|
-
position: relative;
|
|
90
|
-
overflow: hidden;
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
.scanline::after {
|
|
94
|
-
content: " ";
|
|
95
|
-
display: block;
|
|
96
|
-
position: absolute;
|
|
97
|
-
top: 0;
|
|
98
|
-
left: 0;
|
|
99
|
-
right: 0;
|
|
100
|
-
bottom: 0;
|
|
101
|
-
background: linear-gradient(to bottom,
|
|
102
|
-
transparent 50%,
|
|
103
|
-
rgba(var(--primary), 0.02) 50%);
|
|
104
|
-
background-size: 100% 4px;
|
|
105
|
-
z-index: 2;
|
|
106
|
-
pointer-events: none;
|
|
107
|
-
animation: scanline-move 10s linear infinite;
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
@keyframes scanline-move {
|
|
111
|
-
0% {
|
|
112
|
-
background-position: 0 0;
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
100% {
|
|
116
|
-
background-position: 0 100%;
|
|
117
|
-
}
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
.glow-pulse {
|
|
121
|
-
animation: glow-pulse 2.5s ease-in-out infinite;
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
@keyframes glow-pulse {
|
|
125
|
-
|
|
126
|
-
0%,
|
|
127
|
-
100% {
|
|
128
|
-
opacity: 0.3;
|
|
129
|
-
transform: scale(1);
|
|
130
|
-
filter: blur(2px);
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
50% {
|
|
134
|
-
opacity: 0.7;
|
|
135
|
-
transform: scale(1.5);
|
|
136
|
-
filter: blur(4px);
|
|
137
|
-
}
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
.card-premium {
|
|
141
|
-
@apply bg-card border border-border/50 shadow-sm transition-all duration-300;
|
|
142
|
-
}
|
|
143
|
-
|
|
144
|
-
.dark .card-premium {
|
|
145
|
-
background-color: hsla(222, 47%, 6%, 0.6);
|
|
146
|
-
backdrop-filter: blur(12px);
|
|
147
|
-
border-color: rgba(255, 255, 255, 0.05);
|
|
148
|
-
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
.dark .card-premium:hover {
|
|
152
|
-
border-color: hsla(238, 83%, 66%, 0.2);
|
|
153
|
-
box-shadow: 0 8px 30px rgba(99, 102, 241, 0.05);
|
|
154
|
-
}
|
|
155
|
-
}
|
|
156
|
-
|
|
157
|
-
.animate-in {
|
|
158
|
-
animation-duration: 400ms;
|
|
159
|
-
animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
|
|
160
|
-
fill-mode: forwards;
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
@keyframes toast-progress {
|
|
164
|
-
from {
|
|
165
|
-
transform: scaleX(1);
|
|
166
|
-
}
|
|
167
|
-
to {
|
|
168
|
-
transform: scaleX(0);
|
|
169
|
-
}
|
|
170
|
-
}
|
|
171
|
-
|
|
172
|
-
.animate-toast-progress {
|
|
173
|
-
animation: toast-progress 5s linear forwards;
|
|
174
|
-
}
|
package/src/client/index.html
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
<!doctype html>
|
|
2
|
-
<html lang="en">
|
|
3
|
-
<head>
|
|
4
|
-
<meta charset="UTF-8" />
|
|
5
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
-
<title>Gravito Zenith</title>
|
|
7
|
-
</head>
|
|
8
|
-
<body>
|
|
9
|
-
<div id="root"></div>
|
|
10
|
-
<script type="module" src="/main.tsx"></script>
|
|
11
|
-
</body>
|
|
12
|
-
</html>
|
package/src/client/main.tsx
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { QueryClient, QueryClientProvider } from '@tanstack/react-query'
|
|
2
|
-
import React from 'react'
|
|
3
|
-
import ReactDOM from 'react-dom/client'
|
|
4
|
-
import App from './App'
|
|
5
|
-
import './index.css'
|
|
6
|
-
|
|
7
|
-
const queryClient = new QueryClient()
|
|
8
|
-
|
|
9
|
-
ReactDOM.createRoot(document.getElementById('root')!).render(
|
|
10
|
-
<React.StrictMode>
|
|
11
|
-
<QueryClientProvider client={queryClient}>
|
|
12
|
-
<App />
|
|
13
|
-
</QueryClientProvider>
|
|
14
|
-
</React.StrictMode>
|
|
15
|
-
)
|
|
@@ -1,162 +0,0 @@
|
|
|
1
|
-
import { motion } from 'framer-motion'
|
|
2
|
-
import { Activity, AlertCircle, ArrowRight, Eye, EyeOff, Lock } from 'lucide-react'
|
|
3
|
-
import { useState } from 'react'
|
|
4
|
-
import { useAuth } from '../contexts/AuthContext'
|
|
5
|
-
import { cn } from '../utils'
|
|
6
|
-
|
|
7
|
-
/**
|
|
8
|
-
* The login page for the Zenith dashboard.
|
|
9
|
-
*
|
|
10
|
-
* Provides a secure, password-protected entry point to the administration
|
|
11
|
-
* console with modern UI effects and smooth animations.
|
|
12
|
-
*
|
|
13
|
-
* @public
|
|
14
|
-
* @since 3.0.0
|
|
15
|
-
*/
|
|
16
|
-
export function LoginPage() {
|
|
17
|
-
const { login } = useAuth()
|
|
18
|
-
const [password, setPassword] = useState('')
|
|
19
|
-
const [showPassword, setShowPassword] = useState(false)
|
|
20
|
-
const [error, setError] = useState('')
|
|
21
|
-
const [isLoading, setIsLoading] = useState(false)
|
|
22
|
-
|
|
23
|
-
const handleSubmit = async (e: React.FormEvent) => {
|
|
24
|
-
e.preventDefault()
|
|
25
|
-
setError('')
|
|
26
|
-
setIsLoading(true)
|
|
27
|
-
|
|
28
|
-
const result = await login(password)
|
|
29
|
-
|
|
30
|
-
if (!result.success) {
|
|
31
|
-
setError(result.error || 'Authentication failed')
|
|
32
|
-
setIsLoading(false)
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
return (
|
|
37
|
-
<div className="min-h-screen bg-background flex items-center justify-center p-4 relative overflow-hidden">
|
|
38
|
-
{/* Background Effects */}
|
|
39
|
-
<div className="absolute inset-0 bg-gradient-to-br from-primary/5 via-transparent to-indigo-500/5" />
|
|
40
|
-
<div className="absolute top-1/4 -left-1/4 w-96 h-96 bg-primary/10 rounded-full blur-3xl animate-pulse" />
|
|
41
|
-
<div
|
|
42
|
-
className="absolute bottom-1/4 -right-1/4 w-96 h-96 bg-indigo-500/10 rounded-full blur-3xl animate-pulse"
|
|
43
|
-
style={{ animationDelay: '1s' }}
|
|
44
|
-
/>
|
|
45
|
-
|
|
46
|
-
{/* Grid Pattern */}
|
|
47
|
-
<div className="absolute inset-0 bg-[linear-gradient(rgba(var(--primary-rgb),0.03)_1px,transparent_1px),linear-gradient(90deg,rgba(var(--primary-rgb),0.03)_1px,transparent_1px)] bg-[size:64px_64px]" />
|
|
48
|
-
|
|
49
|
-
<motion.div
|
|
50
|
-
initial={{ opacity: 0, y: 20 }}
|
|
51
|
-
animate={{ opacity: 1, y: 0 }}
|
|
52
|
-
transition={{ duration: 0.5 }}
|
|
53
|
-
className="relative z-10 w-full max-w-md"
|
|
54
|
-
>
|
|
55
|
-
{/* Logo & Title */}
|
|
56
|
-
<div className="text-center mb-8">
|
|
57
|
-
<motion.div
|
|
58
|
-
initial={{ scale: 0 }}
|
|
59
|
-
animate={{ scale: 1 }}
|
|
60
|
-
transition={{ type: 'spring', delay: 0.2 }}
|
|
61
|
-
className="inline-flex items-center justify-center w-20 h-20 bg-gradient-to-br from-primary to-indigo-600 rounded-3xl shadow-2xl shadow-primary/30 mb-6"
|
|
62
|
-
>
|
|
63
|
-
<Activity size={40} className="text-primary-foreground" />
|
|
64
|
-
</motion.div>
|
|
65
|
-
<h1 className="text-4xl font-black tracking-tighter mb-2">GRAVITO</h1>
|
|
66
|
-
<p className="text-[10px] font-bold text-primary uppercase tracking-[0.4em]">
|
|
67
|
-
Flux Console
|
|
68
|
-
</p>
|
|
69
|
-
</div>
|
|
70
|
-
|
|
71
|
-
{/* Login Card */}
|
|
72
|
-
<div className="card-premium p-8 backdrop-blur-xl">
|
|
73
|
-
<div className="text-center mb-8">
|
|
74
|
-
<h2 className="text-xl font-bold mb-2">Welcome Back</h2>
|
|
75
|
-
<p className="text-sm text-muted-foreground">
|
|
76
|
-
Enter your password to access the console
|
|
77
|
-
</p>
|
|
78
|
-
</div>
|
|
79
|
-
|
|
80
|
-
<form onSubmit={handleSubmit} className="space-y-6">
|
|
81
|
-
{/* Error Message */}
|
|
82
|
-
{error && (
|
|
83
|
-
<motion.div
|
|
84
|
-
initial={{ opacity: 0, y: -10 }}
|
|
85
|
-
animate={{ opacity: 1, y: 0 }}
|
|
86
|
-
className="flex items-center gap-3 p-4 bg-red-500/10 border border-red-500/20 rounded-xl text-red-500"
|
|
87
|
-
>
|
|
88
|
-
<AlertCircle size={18} />
|
|
89
|
-
<span className="text-sm font-medium">{error}</span>
|
|
90
|
-
</motion.div>
|
|
91
|
-
)}
|
|
92
|
-
|
|
93
|
-
{/* Password Field */}
|
|
94
|
-
<div className="space-y-2">
|
|
95
|
-
<label
|
|
96
|
-
htmlFor="password"
|
|
97
|
-
className="text-sm font-bold text-muted-foreground uppercase tracking-widest"
|
|
98
|
-
>
|
|
99
|
-
Password
|
|
100
|
-
</label>
|
|
101
|
-
<div className="relative">
|
|
102
|
-
<Lock
|
|
103
|
-
className="absolute left-4 top-1/2 -translate-y-1/2 text-muted-foreground"
|
|
104
|
-
size={18}
|
|
105
|
-
/>
|
|
106
|
-
<input
|
|
107
|
-
id="password"
|
|
108
|
-
type={showPassword ? 'text' : 'password'}
|
|
109
|
-
value={password}
|
|
110
|
-
onChange={(e) => setPassword(e.target.value)}
|
|
111
|
-
placeholder="Enter console password"
|
|
112
|
-
className={cn(
|
|
113
|
-
'w-full bg-muted/40 border border-border/50 rounded-xl py-4 pl-12 pr-12',
|
|
114
|
-
'text-sm font-medium placeholder:text-muted-foreground/40',
|
|
115
|
-
'focus:outline-none focus:ring-2 focus:ring-primary/30 focus:border-primary/50',
|
|
116
|
-
'transition-all'
|
|
117
|
-
)}
|
|
118
|
-
disabled={isLoading}
|
|
119
|
-
/>
|
|
120
|
-
<button
|
|
121
|
-
type="button"
|
|
122
|
-
onClick={() => setShowPassword(!showPassword)}
|
|
123
|
-
className="absolute right-4 top-1/2 -translate-y-1/2 text-muted-foreground hover:text-foreground transition-colors"
|
|
124
|
-
>
|
|
125
|
-
{showPassword ? <EyeOff size={18} /> : <Eye size={18} />}
|
|
126
|
-
</button>
|
|
127
|
-
</div>
|
|
128
|
-
</div>
|
|
129
|
-
|
|
130
|
-
{/* Submit Button */}
|
|
131
|
-
<button
|
|
132
|
-
type="submit"
|
|
133
|
-
disabled={isLoading || !password}
|
|
134
|
-
className={cn(
|
|
135
|
-
'w-full py-4 rounded-xl font-bold text-sm uppercase tracking-widest',
|
|
136
|
-
'bg-gradient-to-r from-primary to-indigo-600 text-primary-foreground',
|
|
137
|
-
'shadow-lg shadow-primary/30 hover:shadow-xl hover:shadow-primary/40',
|
|
138
|
-
'transition-all duration-300 hover:scale-[1.02] active:scale-[0.98]',
|
|
139
|
-
'disabled:opacity-50 disabled:cursor-not-allowed disabled:hover:scale-100',
|
|
140
|
-
'flex items-center justify-center gap-2'
|
|
141
|
-
)}
|
|
142
|
-
>
|
|
143
|
-
{isLoading ? (
|
|
144
|
-
<div className="w-5 h-5 border-2 border-primary-foreground/30 border-t-primary-foreground rounded-full animate-spin" />
|
|
145
|
-
) : (
|
|
146
|
-
<>
|
|
147
|
-
Access Console
|
|
148
|
-
<ArrowRight size={18} />
|
|
149
|
-
</>
|
|
150
|
-
)}
|
|
151
|
-
</button>
|
|
152
|
-
</form>
|
|
153
|
-
</div>
|
|
154
|
-
|
|
155
|
-
{/* Footer */}
|
|
156
|
-
<p className="text-center mt-6 text-xs text-muted-foreground/50">
|
|
157
|
-
Protected by Gravito Security Layer
|
|
158
|
-
</p>
|
|
159
|
-
</motion.div>
|
|
160
|
-
</div>
|
|
161
|
-
)
|
|
162
|
-
}
|