Skip to main content
The analytics service polls Icecast statistics and sends events to PostHog. It also triggers Pushover alerts for critical stream events.

PostHog events

The following events are sent to PostHog at each poll interval (default: 30 seconds):
EventDescription
stream_listenersPer-mount listener count
stream_total_listenersAggregate listener count across all mounts
stream_source_connectedA mount point came online
stream_source_disconnectedA mount point went offline
stream_silence_detectedDead air detected on the stream
stream_silence_resolvedAudio returned after a silence event
Configure the polling interval with POSTHOG_POLL_INTERVAL in your .env file. Leave POSTHOG_API_KEY empty to disable analytics entirely.

Pushover alerts

AlertPriorityTrigger
Silence detectedHigh (siren)Audio below SILENCE_THRESHOLD_DB for SILENCE_DURATION seconds
Audio resumedLowAudio returns after a silence event
Stream outageHigh (siren)One or more Icecast outputs disconnect
Primary harbor downHigh (siren)Primary studio input disconnects
Secondary harbor downHigh / CriticalSecondary disconnects; escalates to critical when primary is also down
Alerts have a 5-minute cooldown to prevent notification spam.

Configuration

VariableDescriptionDefault
PUSHOVER_USER_KEYYour Pushover user key
PUSHOVER_APP_TOKENYour Pushover application token
SILENCE_THRESHOLD_DBAudio level in dB considered silence-40
SILENCE_DURATIONSeconds of silence before triggering an alert15
POSTHOG_API_KEYPostHog project API key
POSTHOG_HOSTPostHog instance URLhttps://app.posthog.com
POSTHOG_POLL_INTERVALPolling interval in seconds30
You can use a self-hosted PostHog instance by changing POSTHOG_HOST to your own URL.