Files
computer-playbook/roles/web-app-wordpress/config/main.yml
Kevin Veen-Birkenbach 57d5269b07 CSP (Safari-safe): merge -elem/-attr into base; respect explicit disables; no mirror-back; header only for documents/workers
- Add CSP3 support for style/script: include -elem and -attr directives
- Base (style-src, script-src) now unions elem/attr (CSP2/Safari fallback)
- Respect explicit base disables (e.g. style-src.unsafe-inline: false)
- Hashes only when 'unsafe-inline' absent in the final base tokens
- Nginx: set CSP only for HTML/worker via header_filter_by_lua_block; drop for subresources
- Remove per-location header_filter; keep body_filter only
- Update app role flags to *-attr where appropriate; extend desktop CSS sources
- Add comprehensive unit tests for union/explicit-disable/no-mirror-back

Ref: https://chatgpt.com/share/68f87a0a-cebc-800f-bb3e-8c8ab4dee8ee
2025-10-22 13:53:06 +02:00

69 lines
2.0 KiB
YAML

title: "Blog" # WordPress titel
max_upload_size: "256M" # Low default upload size, because you should use Peertube for Videos and Funkwhale for Audio files
plugins:
wp-discourse:
enabled: "{{ 'web-app-discourse' in group_names | lower }}"
daggerhart-openid-connect-generic:
enabled: true
activitypub:
enabled: true
features:
matomo: true
css: false
desktop: true
oidc: true
central_database: true
logout: true
server:
csp:
flags:
style-src-attr:
unsafe-inline: true
script-src-elem:
unsafe-inline: true
script-src-attr:
unsafe-eval: true
whitelist:
worker-src:
- "blob:"
font-src:
- "data:"
- "https://fonts.bunny.net"
script-src-elem:
- "https://cdn.gtranslate.net" # Necessary for translation plugins
- "https://translate.google.com" # Necessary for translation plugins
- "blog.{{ PRIMARY_DOMAIN }}"
style-src-elem:
- "https://fonts.bunny.net"
frame-src:
- "blob:"
- "*"
domains:
canonical:
- "blog.{{ PRIMARY_DOMAIN }}"
aliases: []
docker:
services:
database:
enabled: true
wordpress:
version: latest
image: wordpress
name: wordpress
backup:
no_stop_required: true
volumes:
data: wordpress_data
rbac:
roles:
subscriber:
description: "Can read posts and leave comments but cannot write or manage content"
author:
description: "Can write and manage own posts"
contributor:
description: "Can write and submit posts for review but cannot publish"
editor:
description: "Can publish and manage all posts, including those by other users"
administrator:
description: "Has full administrative access: manage themes, plugins, settings, and users"