Mango Automation in Docker on Ubuntu – Install, Configure & Logs

Installing Mango Automation via Docker on Ubuntu

🧭 Overview

This guide explains how to install and run Mango Automation as a Docker container on an Ubuntu host. It covers:

  1. Installing Docker

  2. Pulling and running the Mango image

  3. Editing mango.properties inside the container

  4. Viewing Mango log files via Docker

  5. Configuring persistent mounts and networking


⚙️ Prerequisites

  • Ubuntu 18.04+ or compatible Linux distribution

  • Sudo privileges on the host

  • Internet access to download Docker and Mango images


▶️ Step 1: Install Docker on Ubuntu

  1. Follow the official Docker instructions for Ubuntu:
    🔗 Install Docker Engine on Ubuntu

  2. After installation, verify Docker works by running:

    1. sudo docker run hello-world
    • You should see “Hello from Docker!” confirming a successful install.

Alt text: Docker “Hello from Docker!” verification message


▶️ Step 2: Pull the Mango Docker Image

  1. Pull the latest Mango image from GitHub Container Registry (current version as of writing: enterprise-m2m2-core-5.4.1):

    1. docker pull ghcr.io/radixiot/mango:latest
  2. Confirm the image is available locally:

    1. docker images ghcr.io/radixiot/mango:latest

Alt text: Terminal showing Mango image downloaded


▶️ Step 3: Run the Mango Container

Use docker run to launch Mango, exposing its HTTP, HTTPS, and internal API ports, and configuring auto-restart:

  1. docker run -d --name mango -p 8080:8080 -p 8443:8443 -p 9090:9090 --restart unless-stopped ghcr.io/radixiot/mango:latest
  • -d: Run in detached mode

  • --name mango: Name the container “mango”

  • --restart unless-stopped: Automatically restart Mango if it stops or on host reboot

Alt text: Starting Mango container with Docker command


▶️ Step 4: Verify Container Status

  1. Check running containers:

    1. docker ps

    You should see the “mango” container listed with its ports.

  2. View resource usage:

    1. docker stats mango
  3. Confirm port mappings:

    1. docker port mango

    Should show 8080→8080, 8443→8443, 9090→9090.

Alt text: docker ps and docker port mango confirming container and ports


▶️ Step 5: Access the Mango Web UI

Once the container is running, open your browser and navigate to:

https://<host-ip>:8443/ui/login
  • Default credentials:

    • Username: admin

    • Password: admin

Alt text: Mango Automation default login page


🛠 Step 6: Edit mango.properties Inside the Container

Mango’s main configuration file, mango.properties, resides at /opt/mango-data/mango.properties in the container. If you need to modify ports, SSL, or other settings, use one of these in-container methods—no vi or nano needed.

1️⃣ Method A: Use sed for In-Place Edits

To edit a single property (e.g., change HTTP port to 8081):

  1. docker exec -it mango bash -c " sed -i 's/^web.port=8080/web.port=8081/' /opt/mango-data/mango.properties "
  1. docker restart mango
  • Matches lines beginning with web.port=8080 and replaces with web.port=8081.

  • Restart Mango to apply changes.


2️⃣ Method B: Append via Here-Document

To append new properties (e.g., disable SSL):


  1. docker exec -it mango bash -c " cat << 'EOF' >> /opt/mango-data/mango.properties # Disable embedded SSL ssl.enabled=false # Custom property additions custom.setting.example=true EOF "
  1. docker restart mango
  • Appends everything between EOF markers to the end of mango.properties.

  • Restart Mango after saving.

Alt text: Appending new properties to mango.properties via here-document


3️⃣ Method C: Overwrite with Here-Document

To rebuild the entire file from scratch:

  1. docker exec -it mango bash -c " cat << 'EOF' > /opt/mango-data/mango.properties # Mango properties rebuilt on $(date) web.port=8081 ssl.enabled=false # Add additional settings here... EOF "
  1. docker restart mango
  • > mango.properties replaces the file.

  • Useful when applying a known-good template.


📸 [Insert Screenshot: Terminal overwriting mango.properties via here-document]

Alt text: Overwriting mango.properties in the container


🔍 Step 7: Check Mango Log Files via Docker

Mango writes log files under /opt/mango-data/logs/ inside the container. To follow logs:

1️⃣ Tail Standard Output / Error

Use docker logs to view what Mango prints to stdout/stderr:

docker logs -f mango
  • -f (follow) streams new log lines in real time.

📸 [Insert Screenshot: Terminal running docker logs -f mango]

Alt text: docker logs streaming Mango container output


2️⃣ Tail Specific Log Files Inside Container

To see full log details (e.g., ma.log):

  1. docker exec -it mango bash -c " tail -f /opt/mango-data/logs/ma.log "
  • Replace ma.log with any other logfile (e.g., hibernate.log, module-xyz.log).

  • Press Ctrl+C to exit tailing.

Alt text: Tailing Mango’s main log file inside container


🏷️ Step 8: Bind-Mounting for Persistent Configuration (Optional)

For easier editing without repeatedly using docker exec, bind-mount a host directory into the container:

  1. Stop and remove the existing container:

    1. docker stop mango
    2. docker rm mango
  2. Start Mango again, bind-mounting a host directory (e.g., /home/ubuntu/mango-data) to /opt/mango-data:

    1. docker run -d --name mango -p 8080:8080 -p 8443:8443 -p 9090:9090 --restart unless-stopped -v /home/ubuntu/mango-data:/opt/mango-data ghcr.io/radixiot/mango:latest
  3. On the host, edit /home/ubuntu/mango-data/mango.properties with any local editor:

    1. nano /home/ubuntu/mango-data/mango.properties
  4. After saving, restart the container so Mango reloads the file:

    1. docker restart mango
📸 [Insert Screenshot: Host editing mango.properties with nano]

Alt text: Editing mango.properties on host with a text editor


⚙️ Step 9: Networking Options (Optional)

To place Mango on a custom Docker network:

  1. Create a network:

    docker network create mango-net
  2. Run Mango on that network:

    1. docker run -d --name mango --network mango-net -p 8080:8080 -p 8443:8443 -p 9090:9090 --restart unless-stopped ghcr.io/radixiot/mango:latest
  3. Mango is then reachable at https://<host-ip>:8443 within that network.


Alt text: Docker network configuration for Mango

🔄 Summary of Common Commands

  1. # Install Docker (Ubuntu) sudo apt update sudo apt install docker.io sudo systemctl enable --now docker # Pull Mango image docker pull ghcr.io/radixiot/mango:latest # Run Mango container docker run -d -p 8080:8080 -p 8443:8443 -p 9090:9090 --restart unless-stopped ghcr.io/radixiot/mango:latest # Edit properties via sed docker exec -it mango bash -c "sed -i 's/^web.port=8080/web.port=8081/' /opt/mango-data/mango.properties" docker restart mango # View logs docker logs -f mango docker exec -it mango bash -c "tail -f /opt/mango-data/logs/ma.log" # Stop & remove container docker stop mango docker rm mango

    • Related Articles

    • Mango v5.4.x - Windows Installation

      ? Overview Installing Mango Automation on a Windows computer is straightforward. This guide walks you through: Setting up Java JDK 17 (Azul Zulu OpenJDK) Downloading and installing Mango Running Mango from the command line Configuring Mango as a ...
    • Installing and Configuring PostgreSQL for Mango

      ? Installing and Configuring PostgreSQL for Mango This guide provides detailed steps to install and configure PostgreSQL for use with Mango OS. You will install PostgreSQL, create a dedicated Mango database and user, and validate Mango’s connection ...
    • Mango v5 Minimum System Requirements

      Overview Mango by Radix IoT is a browser-based, cross-platform application for monitoring, controlling, and analyzing data from sensors, PLCs, subsystems, databases, and web services. Performance depends on the number of data points, configuration, ...
    • Configuring BACnet/IP data source and BACnet publisher in Mango

      ? Overview This guide outlines the steps to configure BACnet/IP communication in Mango OS, including setting up a BACnet Local Device, creating a BACnet/IP Data Source, and publishing points via a BACnet Publisher. These steps allow Mango to ...
    • Configuring Modbus IP Data Source in Mango

      ? Overview The Modbus IP data source in Mango OS is used to gather data from Modbus-compatible devices over an IP network. These devices can reside on a local network, an intranet, or even the public internet. The data source operates by polling the ...