andrius/asterisk

By andrius

Updated 3 days ago

✨📞 Asterisk PBX in 🐳 Docker — Smallest Asterisk ever! 🚀

Image
Networking
Developer tools
115

500K+

andrius/asterisk repository overview

Production-Ready Asterisk PBX Docker Images

Comprehensive Asterisk Docker images supporting all Asterisk PBX versions from legacy 1.2.40 to latest 23.0.0-rc2, with automated builds and optimized multi-stage containers.

Quick Start

# Latest stable
docker run -d -p 5060:5060/udp -p 10000-20000:10000-10499/udp \
  --name asterisk andrius/asterisk:latest

# Check version
docker run --rm andrius/asterisk:latest asterisk -V

# Use release candidate
docker run -d -p 5060:5060/udp andrius/asterisk:23-rc

Supported Versions & Tags

Current Releases
Legacy Support

Complete support for historical versions: 19.8.1, 18.26.4, 17.9.4, 16.30.1, 15.7.4, 14.7.8, 13.38.3, 12.8.2, 11.25.3, 10.12.4, 1.8.32.3, 1.6.2.24, 1.4.44, 1.2.40

Docker Tags Format

This project uses a dual-tagging system: version-specific tags in the format {version}_{os}-{distribution} (e.g., 22.5.2_debian-trixie) for precise deployment, and semantic tags (e.g., latest, stable, 22, 23-rc, 20-cert) for convenient version management.

Primary tags include the full OS and distribution context, while additional semantic tags are defined per version in the build matrix using the additional_tags property. Multi-architecture builds create unified manifests under the same tag names, automatically selecting the correct architecture.

For development, use semantic tags like asterisk:latest or asterisk:stable, and for production a specific tag like asterisk:22.5.2_debian-trixie that guarantee exact version and environment reproducibility.

Key Features

  • Production Optimized: Multi-stage builds, tiny final images
  • Multi-Architecture: AMD64 and ARM64 support for modern versions
  • Modern Stack: PJSIP, WebRTC, ARI, WebSocket transport
  • Smart Variants: Automatic feature detection based on Asterisk version
  • Daily Updates: Automated release discovery and builds
  • Complete Coverage: From legacy addons (1.2.x) to cutting-edge features

Container Configuration

Exposed Ports

We do not expose ports you'd need to. Examples:

  • 5060/tcp, 5060/udp: SIP signaling
  • 10000-10499/udp: RTP media (configurable range)
Volumes
  • /etc/asterisk - Configuration files
  • /var/lib/asterisk - Runtime data, sounds, keys
  • /var/log/asterisk - Log files
  • /var/spool/asterisk - Voicemail, recordings
Environment Variables
  • ASTERISK_UID=1000 - User ID for Asterisk process
  • ASTERISK_GID=1000 - Group ID for Asterisk process

Production Examples

Basic SIP Server
docker run -d \
  --name asterisk-pbx \
  -p 5060:5060/udp \
  -p 10000-20000:10000-20000/udp \
  -v ./asterisk-configs:/etc/asterisk \
  -v asterisk-data:/var/lib/asterisk \
  andrius/asterisk:stable
With Docker Compose
services:
  asterisk:
    image: andrius/asterisk:latest
    ports:
      - "5060:5060/udp"
      - "10000-20000:10000-20000/udp"
    volumes:
      - ./config:/etc/asterisk
      - asterisk-data:/var/lib/asterisk
    restart: unless-stopped

Version-Specific Features

Version RangeFeatures Available
23.xLatest features, PJSIP, WebRTC, ARI
20.x-22.xModern PJSIP stack, certified releases
18.x-19.xStable LTS, full PJSIP support
12.x-17.xPJSIP transition, chan_sip available
1.8.x-11.xPre-PJSIP, chan_sip, transitional
1.2.x-1.6.xLegacy with separate addons

Security & Reliability

  • Regular security updates via automated builds
  • Minimal attack surface with multi-stage builds
  • Comprehensive health checks and monitoring
  • Production-tested configurations

Repository & Documentation

GitHub: andrius/asterisk

Complete documentation, examples, and configuration templates available in the GitHub repository.

Tag summary

Content type

Image

Digest

sha256:83419f3ef

Size

219 MB

Last updated

3 days ago

docker pull andrius/asterisk:testing