feat: Steam and Minecraft game server checks
ci / build (pull_request) Successful in 5m10s
ci / image (pull_request) Successful in 6m44s
ci / test (pull_request) Canceled after 7m6s
ci / lint (pull_request) Canceled after 7m5s

Steam servers are asked for A2S_INFO like the server browser does,
answering the challenge newer servers send. Minecraft Java Edition gets
the server list ping, Bedrock Edition a RakNet unconnected ping. A
minimum of free slots can be required. The protocols are implemented
directly; tested against protocol-accurate test servers and once by
hand against public Java and Bedrock servers.

Closes #96

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017GpWAskjmYtZpuQ5JwYTX3
This commit is contained in:
Sebastian UnterschützandClaude Opus 5.5 committed 2026-11-22 16:56:40 +01:00
1 parent 365152d164
commit f14b760069
11 files changed
+1682 -1101

No files matched your search

+2 -1
View File
@@ -152,7 +152,7 @@ func TestDynamicFamilies(t *testing.T) {
en := catalogKeys(t)["en"]
families := map[string][]string{
"status.": {"up", "degraded", "down", "unknown", "paused", "maintenance"},
"monitors.type_": {"http", "tcp", "tls", "dns", "icmp", "json", "prometheus", "postgres", "mysql", "mssql", "mongodb", "redis", "mqtt", "kafka", "rabbitmq", "grpc", "smtp", "radius", "snmp", "heartbeat", "alertmanager"},
"monitors.type_": {"http", "tcp", "tls", "dns", "icmp", "json", "prometheus", "postgres", "mysql", "mssql", "mongodb", "redis", "mqtt", "kafka", "rabbitmq", "grpc", "smtp", "radius", "snmp", "steam", "minecraft", "heartbeat", "alertmanager"},
"channels.type_": {"webhook", "email", "slack", "discord", "teams", "googlechat", "mattermost", "rocketchat", "telegram", "matrix", "ntfy", "gotify", "pushover", "pushbullet", "signal", "pagerduty", "opsgenie", "apprise"},
"agents.kind_": {"checker", "statuspage"},
"page.status.": {"operational", "degraded", "outage", "unknown", "maintenance"},
@@ -166,6 +166,7 @@ func TestDynamicFamilies(t *testing.T) {
"monitors.db_database_": {"postgres", "mysql", "mssql", "mongodb", "redis"},
"monitors.broker_hint_": {"mqtt", "kafka", "rabbitmq"},
"monitors.snmp_cond_": {"any", "eq", "ne", "contains", "gt", "ge", "lt", "le"},
"monitors.minecraft_": {"java", "bedrock", "hint", "edition"},
"monitors.db_tls_": {"require", "verify", "disable"},
"weekday.": {"0", "1", "2", "3", "4", "5", "6"},
"md.": {"heading", "bold", "italic", "strike", "link", "ul", "ol", "quote", "code", "codeblock", "table", "hr"},
+9
View File
@@ -612,6 +612,8 @@
"monitors.edit": "Monitor bearbeiten",
"monitors.expect_status": "Erwarteter Status (z. B. 2xx, 301)",
"monitors.follow_redirects": "Weiterleitungen folgen",
"monitors.game_min_free_slots": "Mindestens freie Plätze",
"monitors.game_min_free_slots_hint": "0 prüft nur, ob der Server antwortet.",
"monitors.grace": "Toleranz (Sekunden)",
"monitors.grace_hint": "Wie spät ein Ping sein darf, für Jobs, die manchmal länger laufen.",
"monitors.grpc_hint": "Ziel ist host:port. Fragt den Standard-Health-Service von gRPC (grpc.health.v1); die Antwort muss SERVING sein.",
@@ -631,6 +633,10 @@
"monitors.matchers": "Label-Matcher",
"monitors.matchers_hint": "Wie in Prometheus: = und != vergleichen, =~ und !~ prüfen einen regulären Ausdruck gegen den ganzen Wert.",
"monitors.method": "Methode",
"monitors.minecraft_bedrock": "Bedrock Edition",
"monitors.minecraft_edition": "Edition",
"monitors.minecraft_hint": "Ziel ist host:port (Java meist 25565, Bedrock 19132). Pingt den Server wie die Serverliste im Spiel.",
"monitors.minecraft_java": "Java Edition",
"monitors.new": "Neuer Monitor",
"monitors.op_absent": "fehlt",
"monitors.op_contains": "enthält",
@@ -681,6 +687,7 @@
"monitors.snmp_version": "Version",
"monitors.stale_hours": "Verfällt nach (Stunden)",
"monitors.stale_hours_hint": "Ein feuernder Alert, den Alertmanager nicht mehr wiederholt, gilt nach dieser Zeit als beendet. Halte sie über repeat_interval.",
"monitors.steam_hint": "Ziel ist host:port des Query-Ports (meist der Spielport, z. B. 27015). Fragt den Server wie der Steam-Serverbrowser nach seinen Infos (A2S); funktioniert für Source- und die meisten Steam-Spiele.",
"monitors.target": "Ziel",
"monitors.target_hint": "URL für HTTP, host:port für TCP, TLS, Datenbanken und Broker (Kafka: mehrere, durch Komma getrennt), Hostname für DNS und ICMP.",
"monitors.timeout": "Timeout (ms)",
@@ -695,6 +702,7 @@
"monitors.type_icmp": "Ping (ICMP)",
"monitors.type_json": "JSON-API",
"monitors.type_kafka": "Kafka",
"monitors.type_minecraft": "Minecraft-Server",
"monitors.type_mongodb": "MongoDB",
"monitors.type_mqtt": "MQTT",
"monitors.type_mssql": "Microsoft SQL Server",
@@ -706,6 +714,7 @@
"monitors.type_redis": "Redis",
"monitors.type_smtp": "SMTP",
"monitors.type_snmp": "SNMP",
"monitors.type_steam": "Steam-Spieleserver",
"monitors.type_tcp": "TCP-Port",
"monitors.type_tls": "TLS-Zertifikat",
"monitors.uptime_chart": "Uptime pro Zeitraum",
+9
View File
@@ -612,6 +612,8 @@
"monitors.edit": "Edit monitor",
"monitors.expect_status": "Expected status (e.g. 2xx, 301)",
"monitors.follow_redirects": "Follow redirects",
"monitors.game_min_free_slots": "Minimum free slots",
"monitors.game_min_free_slots_hint": "0 only checks that the server answers.",
"monitors.grace": "Grace period (seconds)",
"monitors.grace_hint": "How late a ping may be, for jobs that sometimes run longer.",
"monitors.grpc_hint": "Target is host:port. Asks the standard gRPC health service (grpc.health.v1); the answer must be SERVING.",
@@ -631,6 +633,10 @@
"monitors.matchers": "Label matchers",
"monitors.matchers_hint": "As in Prometheus: = and != compare, =~ and !~ match a regular expression against the whole value.",
"monitors.method": "Method",
"monitors.minecraft_bedrock": "Bedrock Edition",
"monitors.minecraft_edition": "Edition",
"monitors.minecraft_hint": "Target is host:port (Java usually 25565, Bedrock 19132). Pings the server like the in-game server list.",
"monitors.minecraft_java": "Java Edition",
"monitors.new": "New monitor",
"monitors.op_absent": "is absent",
"monitors.op_contains": "contains",
@@ -681,6 +687,7 @@
"monitors.snmp_version": "Version",
"monitors.stale_hours": "Stale after (hours)",
"monitors.stale_hours_hint": "A firing alert Alertmanager stops repeating counts as over after this time. Keep it above repeat_interval.",
"monitors.steam_hint": "Target is host:port of the query port (usually the game port, e.g. 27015). Asks the server for its info like the Steam server browser (A2S); works for Source and most Steam games.",
"monitors.target": "Target",
"monitors.target_hint": "URL for HTTP, host:port for TCP, TLS, databases and brokers (Kafka: several, comma-separated), host name for DNS and ICMP.",
"monitors.timeout": "Timeout (ms)",
@@ -695,6 +702,7 @@
"monitors.type_icmp": "Ping (ICMP)",
"monitors.type_json": "JSON API",
"monitors.type_kafka": "Kafka",
"monitors.type_minecraft": "Minecraft server",
"monitors.type_mongodb": "MongoDB",
"monitors.type_mqtt": "MQTT",
"monitors.type_mssql": "Microsoft SQL Server",
@@ -706,6 +714,7 @@
"monitors.type_redis": "Redis",
"monitors.type_smtp": "SMTP",
"monitors.type_snmp": "SNMP",
"monitors.type_steam": "Steam game server",
"monitors.type_tcp": "TCP port",
"monitors.type_tls": "TLS certificate",
"monitors.uptime_chart": "Uptime per period",