Files
computer-playbook/roles/web-svc-coturn
Kevin Veen-Birkenbach 926def3d01 web-svc-coturn: Add resource limits and fix docker-compose template
- Set CPU, memory reservation/limit, and PID limit for coturn
- Ensure docker_compose_file_creation_enabled and disable git repo pulling
- Move certificate mounts to volumes and fix env var interpolation in command
- Correct realm and user formatting

See: https://chatgpt.com/share/66f65f18-799c-800a-95f4-b6b26511e9cb
2025-09-27 01:40:37 +02:00
..
2025-09-26 22:11:55 +02:00

Coturn

This folder contains the role to deploy and manage a Coturn service.

Description

Coturn is a free and open-source TURN (Traversal Using Relays around NAT) and STUN (Session Traversal Utilities for NAT) server.
It enables real-time communication (RTC) applications such as WebRTC to work reliably across NATs and firewalls.

Without TURN/STUN, video calls, conferencing, and peer-to-peer connections often fail due to NAT traversal issues.
Coturn solves this by acting as a relay server and/or discovery service for public IP addresses.

More background:

Overview

This role deploys Coturn via Docker Compose using the sys-stk-semi-stateless stack.
It automatically configures:

  • TURN and STUN listening ports
  • Relay port ranges
  • TLS certificates (via Lets Encrypt integration)
  • Long-term credentials and/or REST API secrets

Typical use cases:

  • Nextcloud Talk
  • Jitsi
  • BigBlueButton
  • Any WebRTC-based application

Features

  • Stateless container deployment (no database or persistent volume required)
  • Automatic TLS handling via sys-stk-front-base
  • TURN and STUN support over TCP and UDP
  • Configurable relay port ranges for scaling
  • Integration into Infinito.Nexus inventory/variable system

Further Resources