- Rename sys-svc-webserver -> sys-svc-webserver-core - Rename sys-stk-front-pure -> sys-svc-webserver-https - Update includes, run_once flags, and docs across: * sys-ctl-mtn-cert-renew * sys-front-inj-* * sys-stk-front-proxy * sys-svc-certs * sys-svc-cln-domains * web-opt-rdr-* * web-svc-* - Remove redundant webserver include in web-opt-rdr-www - Fix documentation links Ref: ChatGPT conversation https://chatgpt.com/share/68d6cea2-3570-800f-acb3-c3277317f17b
🌐 Global JavaScript Injector for Nginx
Description
This Ansible role injects a custom JavaScript snippet into all HTML responses served by Nginx. It leverages Nginx’s sub_filter
to seamlessly insert your application-specific script just before the closing </head>
tag, ensuring that your code runs on every page load—perfect for global feature flags, analytics, or UI enhancements.
Features
-
One-line Script Injection
Collapses your JavaScript into a single line and injects it viasub_filter
for minimal footprint and maximal compatibility. -
Easy CSP Integration
Automatically computes and appends a CSP hash entry for your script, so you can lock down Content Security Policy without lifting a finger. -
Conditional Activation
Activates only when you enable thejavascript
feature for a given application, keeping your server blocks clean and performant. -
Debug Mode
Supports anMODE_DEBUG
flag that appends optionalconsole.log
statements for easier troubleshooting in staging or development.
Author
Developed by Kevin Veen-Birkenbach Consulting & Coaching Solutions — veen.world
Happy automating! 🎉