Docker

  • Prerequisites

    • Linux VM with the latest version of Docker Engine
    • access to Docker Hub
    • available ports: 5432 and 8443
    • Docker compose CLI plugin

  • Create .env file
    cd ~/xormon-ng
    vi .env
    File contents
    APP_PORT=8443
    APP_TIMEZONE=<timezone>
    DB_HOST=timescaledb
    DB_PORT=5432
    DB_USERNAME=postgres
    DB_PASSWORD=<db_password>
    DB_DATABASE=xormon
    APP_DEBUG=false
    APP_SECRET=<xormon-secret>
    Replace <variables> with values:
    • <timezone> : Linux timezone, e.g. 'Europe/Prague' (see TZ in /usr/share/zoneinfo)
    • <db_password> : password used for running Timescale DB container
    • <xormon-secret> : any unique string, e.g. 'my-xormon-secret'

  • Create docker-compose YAML file
    cd ~/xormon-ng
    vi docker-compose.yml
    file contents (copy/paste)
    services:
      timescaledb:
        image: timescale/timescaledb:latest-pg16
        restart: unless-stopped
        environment:
          - POSTGRES_USER=${DB_USERNAME}
          - POSTGRES_PASSWORD=${DB_PASSWORD}
        volumes:
          - ./data:/var/lib/postgresql/data
        ## uncomment if you want to have Postgres (TSDB) port opened on host
        # ports:
        #  - '5432:5432'
    
      xormon:
        image: xorux/xormon-ng:latest
        restart: unless-stopped
        depends_on:
          - timescaledb
        env_file: .env
        volumes:
          - ./files:/usr/src/app/server-nest/files
        ports:
          - ${APP_PORT}:${APP_PORT}
          - 8162:8162
  • Run containers
    docker compose up -d
  • Navigate to XorMon NG GUI
    https://<docekr_vm_IP>:8443/
    Default login: xormon / xormon

  • XorMon NG upgrade

    Do not use 'Application Upgrade' form in GUI!
    docker compose pull
    docker compose up -d
  • Prerequisites

    • Linux VM with the latest version of Docker Engine
    • access to Docker Hub
    • available ports: 5432 and 8443

  • Create a directories for permanent data storage
    mkdir -p /var/xormon-ng/data
    mkdir -p /var/xormon-ng/files
  • Timescale DB

    • Prepare a password for the databse and note it down

    • Run the database container
      docker run -v /var/xormon-ng/data:/var/lib/postgresql/data \
      -d --name timescaledb -p 5432:5432 \
      -e POSTGRES_PASSWORD=<db_password> timescale/timescaledb:latest-pg16
    • Note: Upgrading from older PostgreSQL versions within the TimescaleDB container
      If you already have data in the /var/xormon-ng/data volume from older PostgreSQL versions and want to upgrade the TimescaleDB container to PostgreSQL 16, please refer to the manual provided in the official TimescaleDB documentation.

      If the /var/xormon-ng/data directory is empty, you can proceed with the standard installation process

  • XorMon NG

    • Prepare a configuration file
      cd /var/xormon-ng
      vi ./xormon-ng.env
      file contents (copy/paste)
      APP_PORT=8443
      APP_TIMEZONE=<timezone>
      DB_HOST=timescaledb
      DB_PORT=5432
      DB_USERNAME=postgres
      DB_PASSWORD=<db_password>
      DB_DATABASE=xormon
      APP_SECRET=<xormon-secret>
      Replace <variables> with values:
      • <timezone> : Linux timezone, e.g. 'Europe/Prague' (see TZ in /usr/share/zoneinfo)
      • <db_password> : password used for running Timescale DB container
      • <xormon-secret> : any unique string, e.g. 'my-xormon-secret'

    • Run XorMon NG container
      docker run -d --name xormon -p 8443:8443 \
      -v /var/xormon-ng/files:/usr/src/app/server-nest/files \
      --link timescaledb:timescaledb --env-file ./xormon-ng.env xorux/xormon-ng:latest
  • Navigate to XorMon NG GUI
    https://<docekr_vm_IP>:8443/
    Default login: xormon / xormon

  • XorMon NG upgrade

    Do not use 'Application Upgrade' form in GUI!

    Stop, remove and re-run XorMon NG container
    docker rm -f {UUID|name}
    docker run -d --name xormon -p 8443:8443 \
    -v /var/xormon-ng/files:/usr/src/app/server-nest/files \
    --link timescaledb:timescaledb --env-file ./xormon-ng.env xorux/xormon-ng:latest