docs: document the Content Security Policy settings the map requires - #94
Merged
TheWitness merged 2 commits intoAug 16, 2026
Merged
Conversation
Cacti's default policy blocks maps.googleapis.com, which presents as a blank Maps tab with no message in the UI. Signed-off-by: Thomas Vincent <thomasvincent@gmail.com>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the plugin documentation to explain how Cacti’s Content Security Policy (CSP) can block Google Maps JavaScript, resulting in a blank Maps tab, and provides the required configuration to resolve it.
Changes:
- Adds Installation guidance for required CSP settings to allow Google Maps scripts to load.
- Updates “Possible Bugs” to direct users to the browser console and identify CSP-related failures.
Suppressed comments (1)
README.md:130
- This inline code span is also split across a line break (backtick opens on the first line and closes on the next), which can render as stray backticks rather than
Refused to load the script. Keep the code span on a single line.
A blank Maps tab is almost always the Content Security Policy rather than a
fault in the plugin. Open the browser console first: a `Refused to load the
script` entry naming `maps.googleapis.com` means the two settings described
under Installation have not been applied.
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
This was referenced Aug 16, 2026
Open
…e policy Signed-off-by: Thomas Vincent <thomasvincent@gmail.com>
TheWitness
approved these changes
Aug 16, 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.
Three issues report the same failure with the same root cause: Cacti's default CSP is
script-src 'self' 'unsafe-inline', the map loads its JavaScript frommaps.googleapis.com, the browser blocks it, and the Maps tab renders blank with nothing in the Cacti UI to explain why.The workaround has been known since at least 2023 (#16), but the README never documented it. This adds it to Installation and points Possible Bugs at the browser console.
Core has provided the two required settings since 1.2.15:
https://maps.googleapis.com https://maps.gstatic.comThe Google loader calls
eval(), so alternate sources alone is not enough.Closes #12
Closes #15
Closes #16
Docs only, no code change.
markdownlintclean against the rules.mdl_style.rbleaves enabled.A follow-up could detect the missing setting at page load and raise a Cacti message instead of leaving a blank page, but that needs a live install to test and is kept out of this PR.