WebserverΒΆ
DescriptionΒΆ
This Ansible role installs and configures NGINX as a core HTTP/stream server on Arch Linux systems. It provides:
HTTP serving with MIME types, gzip compression, caching, and custom
NGINX.conftemplating.TCP/UDP stream support via the NGINX Streams module.
Directory management for configuration,
sites-available/enabled, cache, and data.Debugging helpers: log formats and instructions for general and detailed troubleshooting.
OverviewΒΆ
This role installs and configures Nginx HTTP and stream modules with performance-tuned defaults.
CosmosΒΆ
The diagram places Webserver in the Infinito.Nexus cosmos: the components it deploys (capabilities), the central services it consumes (dependencies), and its outward reach (federation and bridged external networks).
flowchart LR
subgraph role [sys-svc-webserver-core π»]
svc_svc_webserver_core["svc-webserver-core"]
end
Solid 1:1 edges are fixed relationships; dashed 0..1 edges are conditional (enabled only in matching deployments); red 0..0 edges are turned off in this role. Node markers show the roleβs deploy modes (π» host, π³ compose, π swarm); β marks a service that is explicitly turned off, and βοΈ an Ansible role dependency declared in meta/main.yml.
FeaturesΒΆ
Package installation of
NGINXandNGINX-mod-stream.Idempotent setup: tasks run only once per host.
Configurable reset and cleanup modes to purge and recreate directories.
Custom
NGINX.conftemplate with sensible defaults for performance and security.Stream proxy support: includes
streamblock for TCP/UDP proxies.Cache directory management: cleanup and recreation based on
MODE_CLEANUP.
Debugging TipsΒΆ
General logs:
journalctl -f -u NGINXFilter by host:
journalctl -u NGINX -f | grep "{{ inventory_hostname }}"Enable detailed format: set
MODE_DEBUG: trueand reload NGINX.Redacted request path: both access log formats write the path without query string, Referer or basic-auth user. Path segments after a password-reset, e-mail confirmation, e-mail login or account activation route (e.g.
/password/reset/,/confirm-email/) are written as[redacted]; extend the$infinito_access_log_pathmap in nginx.conf.j2 for further token routes.
CreditsΒΆ
Implemented by Kevin Veen-Birkenbach. Part of the Infinito.Nexus Project and maintained by Kevin Veen-Birkenbach. Licensed under the Infinito.Nexus Community License (Non-Commercial).