Skip to content

Installation

HSM Wiki Update edited this page Mar 22, 2026 · 22 revisions

Installation

HSM Server is distributed as a Docker image. This page covers all deployment methods.


Prerequisites

  • Docker installed and running
  • Ports 44330 and 44333 available on the host

Method 1 — Docker Compose (recommended)

1. Download the compose file:

curl -O https://raw.githubusercontent.com/SoftFx/Hierarchical-Sensor-Monitoring/master/docker-compose.yml

Or create it manually:

services:
  app:
    image: 'hsmonitoring/hierarchical_sensor_monitoring:latest'
    restart: unless-stopped
    user: '0'
    ports:
      - '44330:44330'
      - '44333:44333'
    volumes:
      - ./Logs:/app/Logs
      - ./Config:/app/Config
      - ./Databases:/app/Databases
      - ./DatabasesBackups:/app/DatabasesBackups

2. Start the server:

docker compose up -d

3. Open the web UI:

Go to https://localhost:44333 in your browser. Accept the self-signed certificate warning.

Default credentials: login default, password default. Change the password immediately.


Method 2 — docker run (manual)

1. Pull the image:

docker pull hsmonitoring/hierarchical_sensor_monitoring:latest

2. Run the container:

docker run -u 0 -d \
  --restart unless-stopped \
  -v /host/path/Logs:/app/Logs \
  -v /host/path/Config:/app/Config \
  -v /host/path/Databases:/app/Databases \
  -v /host/path/DatabasesBackups:/app/DatabasesBackups \
  -p 44330:44330 \
  -p 44333:44333 \
  hsmonitoring/hierarchical_sensor_monitoring:latest

Replace /host/path/ with an actual directory on your machine.

Windows example:

docker run -u 0 -d ^
  --restart unless-stopped ^
  -v C:\HSM\Logs:/app/Logs ^
  -v C:\HSM\Config:/app/Config ^
  -v C:\HSM\Databases:/app/Databases ^
  -v C:\HSM\DatabasesBackups:/app/DatabasesBackups ^
  -p 44330:44330 ^
  -p 44333:44333 ^
  hsmonitoring/hierarchical_sensor_monitoring:latest

Method 3 — Script

Ready-made scripts are available in the repository:

PowerShell (Windows):

Download and run docker_scripts/HSMserver/server_load.ps1

.\server_load.ps1

Bash (Linux/macOS):

Download and run docker_scripts/HSMserver/load.sh

chmod +x load.sh && ./load.sh

The scripts pull the latest image and start the container with the correct volume and port mappings.


Volume Mounts — Important

Always mount these four directories. Without them, all data is lost when the container is stopped or updated:

Host path Container path Contents
./Logs /app/Logs Application logs
./Config /app/Config appsettings.json, TLS certificates
./Databases /app/Databases All sensor data (LevelDB)
./DatabasesBackups /app/DatabasesBackups Automatic database backups

The Databases volume is the most critical — it contains all sensor history and configuration. Never remove it without a backup.


Ports

Port Protocol Purpose
44330 HTTPS Sensor data ingestion — used by DataCollector and REST API
44333 HTTPS Web UI

If these ports are already in use, change them in docker-compose.yml and in Config/appsettings.json:

ports:
  - '44331:44330'   # host port : container port
  - '44334:44333'
"Kestrel": {
  "SensorPort": 44330,
  "SitePort": 44333
}

Note: the Kestrel config defines the ports the server listens on inside the container. The left side of the Docker port mapping is what you expose on the host.


Updating

To update to the latest version:

# Pull the new image
docker pull hsmonitoring/hierarchical_sensor_monitoring:latest

# Restart with Docker Compose (data is preserved in volumes)
docker compose down
docker compose up -d

Or with docker run — stop and remove the old container, then run the docker run command again. Volumes are not affected.


First Login

After starting the server, open https://localhost:44333.

  • Username: default
  • Password: default

Go to Account → Settings and change the password before doing anything else.


Next Steps

Clone this wiki locally