WAN tickets: one per incident, notice UniFi updates, maintenance button
Lint / JS (eslint) (push) Successful in 42s
Lint / Python (flake8) (push) Successful in 1m35s
Lint / Notify on failure (push) Skipped
Lint / Deploy (push) Skipped
Security / Python Security (bandit) (push) Successful in 1m3s
Test / Python Tests (pytest) (push) Successful in 1m5s
Lint / Python (flake8) (pull_request) Successful in 58s
Lint / JS (eslint) (pull_request) Successful in 8s
Lint / Notify on failure (pull_request) Skipped
Lint / Deploy (pull_request) Skipped
Security / Python Security (bandit) (pull_request) Successful in 1m1s
Test / Python Tests (pytest) (pull_request) Successful in 1m10s
Lint / JS (eslint) (push) Successful in 42s
Lint / Python (flake8) (push) Successful in 1m35s
Lint / Notify on failure (push) Skipped
Lint / Deploy (push) Skipped
Security / Python Security (bandit) (push) Successful in 1m3s
Test / Python Tests (pytest) (push) Successful in 1m5s
Lint / Python (flake8) (pull_request) Successful in 58s
Lint / JS (eslint) (pull_request) Successful in 8s
Lint / Notify on failure (pull_request) Skipped
Lint / Deploy (pull_request) Skipped
Security / Python Security (bandit) (pull_request) Successful in 1m1s
Test / Python Tests (pytest) (pull_request) Successful in 1m10s
A UniFi Network update on 2026-11-12 dropped the UDM's WAN, Smart Power power-cycled the modem, and Gandalf opened two tickets for the one event. - Modem and WAN reports from one check cycle open a single ticket, led by the most urgent, with the rest listed under "Also seen in this incident". A report while the modem has an open alert, or one that ended under 30 minutes ago, becomes a comment on that ticket instead. - UniFi update log entries (NETWORK_UPDATED, FIRMWARE_UPDATED_V2 and the like) add a note to modem/WAN tickets from 20 minutes before the update to 15 after, and hold new modem/WAN tickets for 15 minutes. - A Maintenance button for admins starts a global suppression for 30 min to 4 hours, with a banner on every page and End now. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
6b03fe7b44
commit
379e3be365
11 files changed
+541
-28
No files matched your search
+57
-1
@@ -125,6 +125,10 @@
|
||||
<span class="lt-header-user">{{ _uname }}</span>
|
||||
{% if user.groups and 'admin' in user.groups %}
|
||||
<span class="lt-badge lt-badge-admin" aria-label="Administrator">ADMIN</span>
|
||||
{% if not maintenance %}
|
||||
<button type="button" class="lt-btn lt-btn-ghost lt-btn-sm" data-action="start-maintenance"
|
||||
title="Pause all tickets while you work on the network">Maintenance</button>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
|
||||
<!-- Notification bell: shows active monitoring alerts -->
|
||||
@@ -184,6 +188,20 @@
|
||||
|
||||
<!-- MAIN CONTENT -->
|
||||
<main class="lt-main lt-container" id="main-content">
|
||||
{% if maintenance %}
|
||||
<div class="maint-banner" role="status">
|
||||
<span class="maint-banner-text">
|
||||
<strong>Maintenance:</strong> Gandalf is not opening tickets
|
||||
{% if maintenance.expires_at %}until <time class="maint-until" datetime="{{ maintenance.expires_at }}">{{ maintenance.expires_at }}</time>{% else %}until it is ended{% endif %}.
|
||||
Alerts are still recorded, and anything still failing afterwards gets a ticket.
|
||||
<span class="maint-reason">{{ maintenance.reason }}{% if maintenance.suppressed_by %} ({{ maintenance.suppressed_by }}){% endif %}</span>
|
||||
</span>
|
||||
{% if user.groups and 'admin' in user.groups %}
|
||||
<button type="button" class="lt-btn lt-btn-secondary lt-btn-sm" data-action="end-maintenance"
|
||||
data-sup-id="{{ maintenance.id }}">End now</button>
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% block content %}{% endblock %}
|
||||
</main>
|
||||
|
||||
@@ -203,9 +221,47 @@
|
||||
<span class="lt-footer-sep">|</span>
|
||||
<button type="button" class="lt-footer-hint" data-action="show-keyboard-help"><span class="lt-footer-key">[ ? ]</span> HELP</button>
|
||||
</nav>
|
||||
<span>GANDALF — TDS v1.2</span>
|
||||
<span>GANDALF | TDS v1.2</span>
|
||||
</footer>
|
||||
|
||||
{% if user.groups and 'admin' in user.groups and not maintenance %}
|
||||
<!-- MAINTENANCE MODAL: pause every ticket for a while -->
|
||||
<div id="maint-modal" class="lt-modal-overlay"
|
||||
role="dialog" aria-modal="true" aria-labelledby="maint-modal-title" aria-hidden="true">
|
||||
<div class="lt-modal">
|
||||
<div class="lt-modal-header">
|
||||
<h3 class="lt-modal-title" id="maint-modal-title">Start maintenance</h3>
|
||||
<button type="button" class="lt-modal-close" data-modal-close aria-label="Close">✕</button>
|
||||
</div>
|
||||
<form id="maint-form">
|
||||
<div class="lt-modal-body">
|
||||
<p class="lt-field-hint maint-intro">Gandalf keeps checking and recording alerts but opens no tickets
|
||||
until this ends. Anything still failing afterwards gets a ticket as usual.</p>
|
||||
<div class="lt-form-group">
|
||||
<label class="lt-label" for="maint-reason">Reason <span class="required">*</span></label>
|
||||
<input type="text" class="lt-input" id="maint-reason" name="reason" maxlength="500"
|
||||
value="Maintenance" required aria-required="true"
|
||||
placeholder="e.g. UniFi Network update">
|
||||
</div>
|
||||
<div class="lt-form-group lt-form-group--last">
|
||||
<span class="lt-label" id="maint-len-label">How long</span>
|
||||
<div class="duration-pills" role="group" aria-labelledby="maint-len-label">
|
||||
<button type="button" class="maint-pill" data-minutes="30" aria-pressed="false">30 min</button>
|
||||
<button type="button" class="maint-pill active" data-minutes="60" aria-pressed="true">1 hr</button>
|
||||
<button type="button" class="maint-pill" data-minutes="120" aria-pressed="false">2 hr</button>
|
||||
<button type="button" class="maint-pill" data-minutes="240" aria-pressed="false">4 hr</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="lt-modal-footer">
|
||||
<button type="button" class="lt-btn lt-btn-secondary" data-modal-close>Cancel</button>
|
||||
<button type="submit" class="lt-btn lt-btn-primary">Start</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<!-- QUICK-SUPPRESS MODAL: available on all pages via [S] shortcut -->
|
||||
<div id="suppress-modal" class="lt-modal-overlay"
|
||||
role="dialog" aria-modal="true" aria-labelledby="suppress-modal-title" aria-hidden="true">
|
||||
|
||||
Reference in new issue
Block a user