Skip to main content

📦 Prerequisites

Ensure your server meets the following system requirements:
  • A VPS or dedicated server with root access (Ubuntu 20.04+ recommended)
  • MySQL server installed and accessible
  • One of the following web servers:
    • Apache or
    • Nginx
  • PHP 8.1 or higher with required extensions (e.g., pdo, openssl, mbstring, tokenizer, xml, ctype, json, bcmath, curl, zip, fileinfo)
  • Certbot (optional, for SSL but recommended)

Step 1: Prepare the Server Environment

1. Update Your System

sudo apt update && sudo apt upgrade -y

2. Install PHP and Required Extensions

sudo apt install -y php php-cli php-common php-mbstring php-xml php-bcmath php-curl php-zip php-mysql php-tokenizer php-fileinfo unzip curl git

3. Install MySQL

sudo apt install -y mysql-server
sudo mysql_secure_installation
Create a dedicated database and user for LicenseForge:
CREATE DATABASE licenseforge;
CREATE USER 'licenseforge'@'%' IDENTIFIED BY 'your_secure_password';
GRANT ALL PRIVILEGES ON licenseforge.* TO 'licenseforge'@'%';
FLUSH PRIVILEGES;

4. Install Web Server (Choose One)

Option A: Install Nginx

sudo apt install -y nginx

Option B: Install Apache

sudo apt install -y apache2 libapache2-mod-php
sudo a2enmod rewrite

Step 2: Download and Deploy LicenseForge

  1. Download the Application from the official source: Download LicenseForge
  2. Upload to Your Server Use SCP, SFTP (e.g., WinSCP), or a control panel to upload the archive to your desired directory (e.g. /var/www/licenseforge).
  3. Extract the Archive:
cd /var/www
unzip licenseforge.zip -d licenseforge
  1. Set Correct Permissions:
sudo chown -R www-data:www-data /var/www/licenseforge
sudo chmod -R 755 /var/www/licenseforge

Step 3: Configure Web Server

Nginx Configuration Example

sudo nano /etc/nginx/sites-available/licenseforge.conf
server {
    listen 80;
    server_name yourinstallationurl.tld;

    root /var/www/licenseforge;

    index index.php;

    location / {
        try_files $uri $uri/ /index.php?$query_string;
    }

    location ~ \.php$ {
        include snippets/fastcgi-php.conf;
        fastcgi_pass unix:/run/php/php8.1-fpm.sock;
    }

    location ~ /\.ht {
        deny all;
    }
}

With SSL

sudo apt install certbot python3-certbot-nginx
sudo certbot --nginx -d yourinstallationurl.tld
sudo nano /etc/nginx/sites-available/licenseforge.conf
server {
    listen 80;
    server_name yourinstallationurl.tld;
    root /var/www/licenseforge;
    index index.php;

    location / {
        try_files $uri $uri/ /index.php?$query_string;
    }

    location ~ \.php$ {
        include snippets/fastcgi-php.conf;
        fastcgi_pass unix:/run/php/php8.1-fpm.sock;
    }
}

server {
    listen 443 ssl;
    server_name yourinstallationurl.tld;
    root /var/www/licenseforge;
    index index.php;

    ssl_certificate /etc/letsencrypt/live/yourinstallationurl.tld/fullchain.pem;
    ssl_certificate_key /etc/letsencrypt/live/yourinstallationurl.tld/privkey.pem;

    location / {
        try_files $uri $uri/ /index.php?$query_string;
    }

    location ~ \.php$ {
        include snippets/fastcgi-php.conf;
        fastcgi_pass unix:/run/php/php8.1-fpm.sock;
    }
}
Enable site:
sudo ln -s /etc/nginx/sites-available/licenseforge.conf /etc/nginx/sites-enabled/
sudo systemctl restart nginx

Apache Configuration Example

Without SSL

sudo nano /etc/apache2/sites-available/licenseforge.conf
<VirtualHost *:80>
    ServerName yourinstallationurl.tld
    DocumentRoot /var/www/licenseforge

    <Directory /var/www/licenseforge>
        AllowOverride All
        Require all granted
    </Directory>
</VirtualHost>

With SSL

sudo apt install python3-certbot-apache
sudo certbot --apache -d yourinstallationurl.tld
sudo nano /etc/apache2/sites-available/licenseforge.conf
<VirtualHost *:80>
    ServerName yourinstallationurl.tld
    DocumentRoot /var/www/licenseforge

    <Directory /var/www/licenseforge>
        AllowOverride All
        Require all granted
    </Directory>

    RewriteEngine On
    RewriteCond %{HTTPS} off
    RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [L,R=301]
</VirtualHost>

<VirtualHost *:443>
    ServerName yourinstallationurl.tld
    DocumentRoot /var/www/licenseforge

    SSLEngine on
    SSLCertificateFile /etc/letsencrypt/live/yourinstallationurl.tld/fullchain.pem
    SSLCertificateKeyFile /etc/letsencrypt/live/yourinstallationurl.tld/privkey.pem

    <Directory /var/www/licenseforge>
        AllowOverride All
        Require all granted
    </Directory>
</VirtualHost>
Enable site and restart:
sudo a2ensite licenseforge.conf
sudo systemctl reload apache2

Step 4: Run the Web-Based Installer

  1. Visit:
    https://yourinstallationurl.tld/installer
    
  2. Complete the form fields:
    • Database Host: localhost
    • Database Name: licenseforge
    • Database Username: licenseforge
    • Database Password: your_secure_password
    • Site Details: Fill in as required (e.g., admin email, password, company info)
    • And other information if required
  3. Submit the form to complete the setup.

✅ Installation Complete

Once the installer is successfully finished, access the LicenseForge environment:
  • Admin Dashboard: https://yourinstallationurl.tld/dashboard
  • User Registration: https://yourinstallationurl.tld/register
  • User/Admin Login: https://yourinstallationurl.tld/login
  • User Dashboard: https://yourinstallationurl.tld/dashboard/me

🧭 You’re Ready to Go

LicenseForge is now live and ready to manage your licensing operations in a secure and self-hosted environment.
I