Documentation
Install using Docker

Install Using Docker

This guide is incomplete. Please help us complete it using the "Edit this page" button in the sidebar. Thanks!

But wait... What is Docker?

Docker containers isolate the app from the host system and solve the "it works on my machine" headache. With this method, everyone using Docker runs virtually the same environment as the others. This is a great way to ensure that everyone has the same environment, thus making it less likely to have problems.

Docker also lets you run multiple containers on the same machine with different configurations. To learn more about containers, we strongly advise you to read Docker's explanation (opens in a new tab) first.

Instructions

Before going further, please make sure you have the Docker Engine and Docker Compose installed. To install the Docker Engine, visit Docker's installation page (opens in a new tab). To install Docker Compose, visit Docker's compose installation page (opens in a new tab).

Using the image with Docker Compose

This is an example of a docker-compose.yml file. You should change the values to suit your needs:

version: "3.9"
services:
  fossbilling:
    image: fossbilling/fossbilling
    restart: always
    ports:
      - 80:80
    volumes:
      - fossbilling:/var/www/html
  mysql:
    image: mysql:8.0
    restart: always
    environment:
      MYSQL_DATABASE: exampledb
      MYSQL_USER: exampleuser
      MYSQL_PASSWORD: examplepass
      MYSQL_RANDOM_ROOT_PASSWORD: '1'
    volumes:
      - mysql:/var/lib/mysql
 
volumes:
  fossbilling:
  mysql:

Run docker compose up to start the containers. The first startup will take a while, this is because Docker will download the images.

Then, use the web interface to install FOSSBilling. If you used this example, the database host field in the installer should be filled as mysql. Other fields should be self-explanatory.

Post-installation steps