Skip to content

About

a docker based on https://github.com/fusionpbx/fusionpbx-install.sh

Topics

Resources

Stars

2 stars

Watchers

0 watching

Forks

 
 

Latest commit

 

History

28 Commits

Folders and files

Repository files navigation

FusionPBX Docker

Docker Hub License

A comprehensive Docker solution for FusionPBX, providing a complete VoIP platform with all necessary components pre-configured and ready to deploy.

Stack: Ubuntu 24.04 • FusionPBX 5.4.7 • FreeSWITCH 1.10.12 • PHP 8.3 • PostgreSQL 16

📚 References

📋 Table of Contents

🏗️ Software Stack

Component Version
Base OS Ubuntu 24.04
FusionPBX 5.4.7
FreeSWITCH 1.10.12
PHP 8.3
PostgreSQL 16

📦 Included Services

The Docker image includes the following services:

  • iptables - Firewall management
  • sngrep - SIP packet capture tool
  • fusionpbx - Web-based PBX system
  • php - PHP runtime
  • nginx - Web server
  • postgres - Database server
  • freeswitch - Voice over IP platform
  • fail2ban - Intrusion prevention system

🚀 Quick Start

Step 1: Configure Permissions

Set the proper ownership for the config directory:

sudo chown 33:33 config -R

Step 2: Choose Your Deployment Method

Option A: Use Pre-built Image (Recommended)

docker pull michaelfangtw/fusionpbx-docker:5.4

Option B: Build Locally

If you want to build the image locally: you can change password in config.sh

docker build -t fusionpbx-docker:5.4 .

Step 3: Configure Docker Compose

The docker-compose.yaml file is already configured. Choose your preferred method:

  • Pre-built image (default): Uses michaelfangtw/fusionpbx-docker:5.4
  • Local build: Uncomment the build section in the compose file
services:
  pbx:
    # 1.Use pre-built image from Docker Hub
    image: michaelfangtw/fusionpbx-docker:5.4
    
    # 2.Or build locally (uncomment to use)
    # build:
    #   context: .
  
    #3. use local 
    #image: fusionpbx-docker:5.4



    # Host networking for RTP port range
    network_mode: "host"
    container_name: fusionpbx
    restart: always
    privileged: true

    # Persist configuration
    volumes:
      - ./config/fusionpbx:/etc/fusionpbx

    entrypoint: ["/usr/sbin/init"]

Step 4: Start the Container

docker compose up -d

Step 5: Access the Web Interface

Once the container is running, access FusionPBX at:

  • URL: http://localhost
  • Username: admin@localhost
  • Password: password don't forget to change password

📁 Project Structure

fusionpbx-install-docker/
├── config/                    # Configuration files
│   └── fusionpbx/            # FusionPBX configuration
├── docker-compose.yaml       # Docker Compose configuration
├── Dockerfile                # Docker image definition
├── build.sh                  # Build script
├── compose.sh                # Compose helper script
├── config.sh                 # Configuration script
├── push.sh                   # Push script
└── README.md                 # Documentation

🌐 Network Configuration

This container uses host networking mode to properly handle RTP traffic for VoIP communications. This means:

  • All services are accessible on the host's network interface
  • No port mapping is required
  • FreeSWITCH can properly handle media streams

💾 Data Persistence

Configuration data is persisted through Docker volumes:

Host Path Container Path Description
./config/fusionpbx /etc/fusionpbx FusionPBX configuration files

⚙️ Requirements

  • Docker Engine: 20.10+
  • Docker Compose: v2.0+
  • Operating System: Linux (recommended for host networking mode)

🔐 Default Credentials

🌐 Web Interface

  • URL: http://localhost
  • Username: admin@localhost
  • Password: password don't forget to change password

🗄️ Database (PostgreSQL)

⚠️ IMPORTANT: Do not change these credentials - they are required for proper operation

  • Host: localhost
  • User: fusionpbx
  • Password: password don't forget to change password

🔧 Troubleshooting

🌐 Web Interface Issues

Problem: Cannot Access Web Interface

If you can't access the web interface at http://localhost:

  1. Check container status:

    docker ps
  2. View container logs:

    docker logs fusionpbx
  3. Check port availability:

    sudo netstat -tulpn | grep :80

Problem: Login Issues

If you cannot log in to the web interface:

  1. Access the container:

    docker exec -it fusionpbx /bin/bash
  2. Backup existing configuration:

    mv /etc/fusionpbx/config.conf /etc/fusionpbx/config.conf.old
  3. Reset admin credentials:

    • Username: admin
    • Password: password don't forget to change password
    • Domain: localhost

🗄️ Database Issues

Problem: Database Connection Failures

If you encounter database-related login failures:

  1. Access the container:

    docker exec -it fusionpbx /bin/bash
  2. Navigate to resources directory:

    cd /usr/src/fusionpbx-install.sh/ubuntu/resources
  3. Recreate the database:

    ./postgresql.sh    # Create database
    ./finish.sh        # Set admin credentials

🐳 Container Management

Save Changes to Local Image

To preserve modifications made inside the container:

# Make changes inside the container
docker exec -it fusionpbx /bin/bash
# ... perform your modifications ...
# Exit the container

# Commit changes to create a new image
TAG=5.4
docker tag fusionpbx-docker:$TAG michaelfangtw/fusionpbx-docker:$TAG
docker login
docker push michaelfangtw/fusionpbx-docker:$TAG

View Container Logs

# Real-time logs
docker logs -f fusionpbx

# Last 100 lines
docker logs --tail 100 fusionpbx

Restart Container

docker restart fusionpbx

📚 Additional Resources

🤝 Contributing

This project includes the complete FusionPBX installer approach for transparency and customization. Feel free to submit issues and pull requests.

📄 License

This project follows the same licensing as the original FusionPBX project. Please refer to the official FusionPBX repository for license details.

About

a docker based on https://github.com/fusionpbx/fusionpbx-install.sh

Topics

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages