Skip to content

Deploying an iTop App

Introduction

iTop is an open-source IT service management and CMDB platform. This guide shows how to containerize iTop with a Dockerfile, connect it to MySQL, persist configs and data, and deploy it to Klutch.sh over HTTP.

Prerequisites

  • GitHub repository containing your Dockerfile.
  • MySQL database (managed or deployed separately).
  • Klutch.sh project ready in klutch.sh/app.

Project structure

.
└── Dockerfile

Sample Dockerfile

FROM combodo/itop:latest
# Default iTop port
ENV APACHE_PORT=80
EXPOSE 80

Required environment variables

  • ITOP_DB_HOST – MySQL host and port (e.g., db:3306)
  • ITOP_DB_NAME
  • ITOP_DB_USER
  • ITOP_DB_PASSWORD
  • ITOP_ADMIN_PASSWORD – initial admin password
  • APACHE_PORT=80

Optional environment variables

  • ITOP_ENV=production
  • ITOP_BASE_URL=https://example-app.klutch.sh
  • PHP_MEMORY_LIMIT=512M

Persistence

Persist configurations, extensions, and uploads:

  • Mount path: /var/www/html/conf
  • Mount path: /var/www/html/data
  • Size: based on expected attachments, logs, and extensions

Networking

  • Protocol: HTTP
  • Internal port: 80
  • Users reach https://example-app.klutch.sh while Klutch.sh routes to port 80 inside the container.
Terminal window
curl -I http://localhost

Deployment on Klutch.sh

  1. Push your Dockerfile to GitHub.
  2. In klutch.sh/app, create a new app and select GitHub as the source.
  3. Klutch.sh automatically detects the Dockerfile in the repository root.
  4. Select HTTP traffic and set the internal port to 80.
  5. Add environment variables for the database connection (ITOP_DB_HOST, ITOP_DB_NAME, ITOP_DB_USER, ITOP_DB_PASSWORD), ITOP_ADMIN_PASSWORD, and any optional settings. Mark secrets as sensitive.
  6. Attach persistent volumes at /var/www/html/conf and /var/www/html/data sized for configs, extensions, and uploads.
  7. Deploy. After the app starts, complete the iTop web installer to finalize schema and admin setup.

Verification

  • UI: open https://example-app.klutch.sh and confirm the iTop installer or login page loads.

  • Quick check:

    Terminal window
    curl -I https://example-app.klutch.sh

Next steps

  • Configure email and authentication providers within iTop.
  • Enable regular backups for MySQL and the mounted volumes.
  • Tune PHP memory limits and enable extensions as needed for your modules.