Repository navigation
feat(alerting): the ntfy.sh copies rendered like the in-house ones (#136) - #719
Merged
Merged
Conversation
) ntfy.sh cannot load stacks/sensitive/ntfy/templates/homelab.yml, so the off-network copies of urgent and security arrived as raw JSON, or at best as ntfy's built-in `alertmanager` layout. It does run inline templates: tpl=yes plus the title, message and priority templates as t, m and p. render-config.sh now builds that query from homelab.yml on every render and appends it to the two *_external_url values, replacing any query SOPS held. There is one template, not a second copy in SOPS. It fails loudly if the file is missing or lacks a key. Checked on the pinned image against the six payload shapes, and on ntfy.sh with one synthetic payload to a throwaway topic: identical title, message and priority 5. The query is about 2.4 KB. Refs #136 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Sep 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
scripts/render-config.shbuilds an inline-template query fromstacks/sensitive/ntfy/templates/homelab.ymlon every render, and appends it to the two*_external_urlvalues. That query istpl=yesplust,mandpfor title, message and priority. Any query already on the SOPS value is replaced, so SOPS holds the barehttps://ntfy.sh/<topic>. The render fails loudly if the file is missing or lacks a key.Why
ntfy.sh can't load a template file, so the off-network copies of
urgentandsecurityarrived as raw JSON, or at best in ntfy's built-in layout. It does run inline templates. Building the query from the tracked file keeps one template instead of a second copy in SOPS that would drift.Blast radius
prometheus only: two rendered URL files change on the next
make render. No SOPS edit is needed; any?template=alertmanageralready there is overwritten in the rendered file.One more job for
homelab.yml: a change to it now needsmake renderon prometheus as well asmake up STACK=sensitiveon trinity. The file's header and the stack README say so.No change to network segmentation or firewall rules
No new port published to a VLAN that could not already reach the service
No credential added outside
secrets/*.sops.yamlVerification
Pinned image: all six payload shapes render through the inline query exactly as through the template file: critical, resolved, grouped, Watchdog, and no annotations. Priority included.
ntfy.sh itself: one synthetic payload, no house names, sent to a random throwaway topic. It rendered as
P5 | 🔴 example service is not reachable / Synthetic payload to test inline templating. / 📍 example-host.Query: the same 2,444-character URL is produced from a bare SOPS value and from one already carrying
?template=alertmanager.Checks:
make validateand shellcheck pass.make validatepassesDeployed:
git pull --ff-only && make renderon prometheus, then a test page seen off Wi-FiDocs updated
Refs #136
🤖 Generated with Claude Code