A real-time dashboard for monitoring PagerDuty incidents, built with Next.js, shadcn/ui, and Tailwind CSS.
- Incident monitoring — View triggered, acknowledged, and resolved incidents for your team
- Auto-refresh — Configurable polling interval (default 30s) with countdown timer
- Real-time webhooks — Optional ngrok-based webhook mode for instant updates via SSE
- Browser notifications — Get notified of new incidents even when the tab is in the background
- Expandable alerts — Drill into alerts for each incident on demand
- Pagination — 30 incidents per page with navigation controls
- Dark/light mode — Theme toggle with system preference detection
- Settings page — Configure API token, team, polling interval, and ngrok URL
- Install dependencies:
npm install - Configure environment (optional):
cp .env.local.example .env.local - Run the development server:
npm run dev - Open http://localhost:3000 and configure your settings.
Settings can be configured via:
- Settings page (
/settings) — API token, team, poll interval, ngrok URL (persisted in localStorage) - Environment variables (
.env.local):PAGERDUTY_API_TOKEN— Server-side API token (not exposed to the browser). When set, the dashboard works without configuring the token in the Settings page.NEXT_PUBLIC_PAGERDUTY_TEAM_ID— Client-side team ID (pre-fills the Settings page).NEXT_PUBLIC_NGROK_URL— Client-side ngrok URL.NEXT_PUBLIC_POLL_INTERVAL— Client-side poll interval in seconds (default: 30).
- Start an ngrok tunnel:
ngrok http 3000 - Enter the ngrok URL in Settings
- The app auto-creates a PagerDuty webhook subscription
- Incidents stream in real-time via Server-Sent Events
A systemd unit file is included to run the dashboard as a service on Linux.
-
Create a dedicated user and install directory:
sudo useradd -r -s /usr/sbin/nologin pagerduty sudo mkdir -p /opt/pagerduty sudo chown pagerduty:pagerduty /opt/pagerduty
-
Clone the repository directly into
/opt/pagerduty:sudo -u pagerduty git clone https://github.com/nyg/pagerduty.git /opt/pagerduty
-
Create a project-level
.npmrcand cache directory so thepagerdutyuser can run npm without access to your personal~/.npmrc:sudo mkdir -p /var/cache/npm-pagerduty sudo chown pagerduty:pagerduty /var/cache/npm-pagerduty printf 'cafile=\ncache=/var/cache/npm-pagerduty\n' | sudo -u pagerduty tee /opt/pagerduty/.npmrc > /dev/null
-
Install dependencies and build:
cd /opt/pagerduty sudo -u pagerduty /usr/bin/npm ci sudo -u pagerduty /usr/bin/npm run build sudo -u pagerduty /usr/bin/npm ci --omit=dev -
Copy your environment file:
sudo cp .env.local /opt/pagerduty/.env.local sudo chown pagerduty:pagerduty /opt/pagerduty/.env.local
-
Install and start the service:
sudo cp pagerduty.service /etc/systemd/system/ sudo systemctl daemon-reload sudo systemctl enable pagerduty sudo systemctl start pagerduty -
Check status and logs:
sudo systemctl status pagerduty journalctl -u pagerduty -f
-
Update the app later:
cd /opt/pagerduty sudo -u pagerduty ./update.sh sudo systemctl restart pagerdutyIf
git pull --ff-onlyfails, resolve local changes or reset the checkout before retrying.
npm test
- Next.js (App Router)
- shadcn/ui (Radix UI + Tailwind CSS)
- TypeScript
- Vitest for testing