Chapter 3: Installation & Deployment Guide

Deploying MartX Enterprise Platform is effortless. Built with an intuitive WordPress-style 5-Step Web Installation Wizard, merchants and agencies can launch a production-ready store within 3 minutes without touching command-line scripts.

3.1 Deployment Pathways & Pre-Installation Checklist

Choose the deployment pathway that best matches your hosting infrastructure:

Deployment Method Target Infrastructure Skill Level Setup Time Recommended For
cPanel Quick Deploy cPanel / DirectAdmin / Plesk Standard 5 Mins Shared hosting users using File Manager and MySQL Wizard.
5-Step Web Wizard cPanel / Shared / VPS / Localhost No-Code (Beginner) 3 Mins All store owners, designers, and standard marketplace buyers.
VPS CLI / DevOps Ubuntu / Debian / Nginx / Forge Advanced 4 Mins Agencies, high-traffic stores, and continuous deployment workflows.
phpMyAdmin Fallback Any MySQL GUI / Offline Localhost Manual Fallback 5 Mins Environments where automated migrations encounter timeout restrictions.
Pre-Installation Checklist (Have These Ready)
  • Product License Key: Your official Product License Key or Order ID from your authorized marketplace or direct purchase invoice.
  • MySQL Database Credentials: Database Host (usually 127.0.0.1 or localhost), Database Name, Database Username, and Password.
  • PHP 8.2+ Environment: Server meets the 13 mandatory PHP extensions outlined in Chapter 2.

3.2 cPanel & Shared Hosting 5-Minute Quick Setup

Before launching the browser installer, upload the application files and configure your MySQL database in cPanel:

Step 1: Upload and Extract Zip Archive

Open cPanel → File Manager, navigate to your desired directory (e.g. /public_html for primary domain, or a subfolder like /public_html/your-subfolder), upload the official martx-v1.0.0.zip file, right-click and choose Extract.

Step 2: Configure DocumentRoot to Point to public/

Laravel applications require web traffic to resolve in the public/ folder:

  • Subdomains & Addon Domains: In cPanel → Domains → Document Root, set the path to public_html/public or public_html/subdomain_name/public.
  • Primary Main Domain (Root): Either configure the Primary Document Root in cPanel, or place files in root and point the web root to public/.
Step 3: MultiPHP Manager & Version Selection

In cPanel → MultiPHP Manager, select your domain and choose PHP 8.2 or PHP 8.3.

Step 4: Create MySQL Database via cPanel Wizard

In cPanel → MySQL Database Wizard:

  1. Create a new Database (e.g., cpaneluser_martx).
  2. Create a Database User with a strong password.
  3. Assign ALL PRIVILEGES to the user for that database.
Step 5: Proceed to Web Installer Wizard

Once your files are extracted and database credentials are created, open your browser and visit https://yourdomain.com/install to complete the 5-step visual installer below!

3.3 The 5-Step Visual Web Installation Wizard Walkthrough

When you open https://yourdomain.com/install, the automated wizard will guide you through 5 progressive screens:

Visual Flowchart: 5-Step Automated Web Installation Pipeline
Under 3 Minutes Setup

The automated browser wizard inspects and prepares your server in 5 progressive, fail-safe phases:

Step 1
Requirements

PHP 8.2+ • 13 Extensions

All Checks Passed
Step 2
Permissions

Storage • Cache • .env

Writable (775 / 755)
Step 3
License Check

Marketplace Code • Email

Domain Verified
Step 4
Database Setup

Schema Migration • Seeds

Tables Migrated
Step 5
Admin Provision

Super Admin • Lockfile

Installation Locked
Step 1: System Requirements Step 1 of 5
1
Requirements
2
Permissions
3
License
4
Database
5
Admin
Step 1: Welcome & Server Requirements Audit

MartX automatically checks your active PHP version and confirms that all 13 required extensions (BCMath, cURL, DOM, Fileinfo, JSON, Mbstring, OpenSSL, PDO, Tokenizer, etc.) are compiled into your PHP runtime.

PHP Version Satisfied: Detected PHP 8.2+ (Required ≥ 8.2.0)
All 13 Extensions Passed
Step 2: Directory Write Permissions Step 2 of 5
Requirements
2
Permissions
3
License
4
Database
5
Admin
Step 2: Storage & Cache Permissions Audit

The wizard verifies that storage/app, storage/framework/cache, storage/logs, and bootstrap/cache possess write permissions (0775 / 0755).

storage/app Writable (775)
storage/framework/cache Writable (775)
storage/logs Writable (775)
bootstrap/cache & .env Writable (775/644)
Step 3: Multi-Marketplace License Verification Step 3 of 5
Requirements
Permissions
3
License
4
Database
5
Admin
Step 3: Select Marketplace & Verify License

Select the official marketplace where you acquired your license and provide your purchase key:

Select Purchase Channel: Interactive: Click tabs to test
Direct / B2B MartX Direct Key
Codester Order ID Key
TemplateMonster Invoice ID Key
Provided upon purchase or retrieved directly from the Client Portal (license.getmartx.com).
Required for 1-click domain transfer authorization.
Domain where license will be registered.
Localhost auto-detection active: Free unrestricted local testing on .test & localhost
First-Time Buyer or Lost Your License Key?
Open License Portal (license.getmartx.com)

If you recently purchased MartX from an authorized marketplace or sales partner and do not have your official License Key, you do not need to wait for author support tickets. You can claim or retrieve your credentials instantly through our 24/7 self-service portal:

  • Instant 3-Input Claim (New Buyers): Visit license.getmartx.com → submit your (1) Purchase Code / Order ID, (2) Marketplace Username, and (3) Marketplace Channel to create your permanent portal account.
  • Direct Portal Login (Existing Accounts): Sign in with your registered email and password to view all your active license keys and bound domains.
  • 1-Click Key Copy: Copy your verified License Key directly from the portal dashboard card and paste it into the field above!
Step 4: Database Configuration & Seeder Step 4 of 5
Requirements
Permissions
License
4
Database
5
Admin
Step 4: Database Connection & Migration Execution

Input your MySQL credentials and test the live connection with 1-click AJAX validation:

Automatically detects domain via url('/') and configures APP_ENV=production with APP_DEBUG=false; no manual .env file editing required!
Auto-Executed
Step 5: Super Admin Account Setup Step 5 of 5
Requirements
Permissions
License
Database
5
Admin
Step 5: Super Administrator Provisioning

Set up your primary merchant root login. This account is provisioned with all 77 RBAC permissions:

Requires 8+ chars, mixed case, numbers & symbols
Installation Completed & Locked 100% Launch Ready

Congratulations! Installation Completed

MartX Enterprise E-Commerce Platform has been successfully configured and secured. The security lock file has been registered at storage/installed, automatically blocking any future re-installation attempts.

Go to Admin Dashboard → Visit Storefront Home

3.4 Ubuntu VPS & Developer CLI Installation

Optional • For DevOps & Cloud Engineers
Merchant Note: If you are using cPanel or shared hosting, you do not need terminal commands! Simply use the 3-minute visual web installer at https://yourdomain.com/install (detailed in Sections 3.2 & 3.3).

For agencies, DevOps engineers, and cloud administrators deploying via SSH terminal, MartX provides a dedicated interactive CLI installation command allowing complete setup directly from the command-line without opening a web browser:

1. Environment & Key
Step 1

Copy the environment template and generate your application's unique encryption key (APP_KEY):

cp .env.example .env
php artisan key:generate

Secures cookie encryptions, user sessions, and signed routes.

2. Database & Domain
Step 2

Create a MySQL database and update your credentials and live domain in .env:

nano .env
APP_URL=https://yourdomain.com
DB_HOST=127.0.0.1
DB_DATABASE=your_database_name
DB_USERNAME=your_database_user
DB_PASSWORD=your_database_password

Ensures migrations connect to the right MySQL database and links render with your live domain.

3. Run MartX CLI Installer
Step 3

Execute the automated terminal setup command in interactive mode:

php artisan martx:install

Guides you through purchase code check, runs migrations, seeds catalogs, and sets up Super Admin.

4. License & Verification
Step 4

Input your Purchase Code and Buyer Email when prompted by the CLI installer:

# Interactive prompt inputs:
Enter License Key: YOUR-PURCHASE-CODE
Enter Buyer Email: [email protected]
✓ Automated CLI verifies with license server instantly.
→ Post-Install Manage anytime at Admin → Settings → License.

Secures live domain locking with 7-day heartbeat cache protection.

Headless CI/CD & Automated 1-Liner Deployment

You can also pass flags directly to martx:install for zero-prompt, fully unattended CI/CD deployment pipelines:

php artisan martx:install --license="YOUR-PURCHASE-CODE" --email="[email protected]" --admin-email="[email protected]" --admin-password="YourStrongPassword123" --app-url="https://yourdomain.com"
Alternative: Manual Terminal Migration & In-Dashboard Activation
Manual Workflow

If you prefer running standard Laravel migration and seeding commands directly, and activating your license later via the Admin Dashboard:

Step 1
Database & Key

Initialize environment, generate application key, and set DB:

cp .env.example .env
php artisan key:generate
nano .env
Step 2
Migrate & Seed

Run schema migrations, catalog seeders, and link media storage:

php artisan migrate:fresh --seed --force
php artisan storage:link
Step 3
Lock Installation

Mark setup complete to bypass web installer on browser hits:

touch storage/installed
php artisan optimize:clear
Step 4
License Activation

Login as Super Admin and activate license in dashboard:

Navigate to Admin → Settings → License & Verification and enter your official License Key.
Or CLI: php artisan martx:activate --key=MARTX-PRO-KEY
Ubuntu Server Permissions & Symlink Script
Ubuntu 24.04 / 22.04 LTS Deployment Script
# 1. Navigate to project root
cd /var/www/html/martx

# 2. Install production dependencies
composer install --no-dev --optimize-autoloader --no-interaction

# 3. Create storage symlink
php artisan storage:link

# 4. Set web server permissions
sudo chown -R www-data:www-data /var/www/html/martx
sudo find /var/www/html/martx -type f -exec chmod 644 {} \;
sudo find /var/www/html/martx -type d -exec chmod 755 {} \;
sudo chmod -R 775 storage bootstrap/cache

# 5. Compile production performance caches
php artisan optimize

3.5 Storage Symlink (storage:link) 3-Tier Multi-Layer Architecture

Product photography, banner slides, and customer invoices are securely stored in storage/app/public/. To make them visible to web visitors, a symbolic link must exist between public/storage and storage/app/public. MartX provides a comprehensive 3-tier fail-safe solution:

Tier 1
100% Automatic at Install

Built-in WordPress-style automation. The Web Installer (Step 5) and CLI command (martx:install) silently create the symlink during setup. 95% of store owners never need to touch anything!

Tier 2
1-Click In-Dashboard Fix

If you ever migrate hosting or restore a cPanel backup, go to Admin Sidebar → Administration & Settings → System Settings → "Theme & Appearance" (Tab). The live health badge indicates symlink status, with a 1-click "Generate Public Symlink" button.

Tier 3
Terminal & cPanel Cron

For DevOps engineers on SSH or servers with locked functions, run php artisan storage:link or create a 1-time cPanel cron task: /usr/local/bin/php /path/artisan storage:link.

3.6 Subdomain, SSL (HTTPS) & APP_URL Configuration Standards

To prevent Mixed Content warnings and CSRF security token mismatches, ensure your environment URL strictly matches your live domain protocol:

Deployment Type Recommended Pattern Target APP_URL in .env
Primary Root Domain https://yourstore.com APP_URL=https://yourstore.com
Dedicated Subdomain (Recommended) https://shop.yourdomain.com APP_URL=https://shop.yourdomain.com
Local Development http://martx.test or http://localhost:8000 APP_URL=http://martx.test

3.7 Post-Installation Security Hardening & Lock Verification

Once the 5-step installer wizard completes, the system executes an automated security lockdown to safeguard your store:

Automatic Installer Lockdown Engine

The installer writes the file storage/installed and establishes secure verification tokens. Subsequent requests to /install are permanently blocked and redirected to the home storefront to prevent unauthorized database resets.

Production 1-Click Optimization Command

For optimal production performance and lower server response latency, run the optimization compilation command once your setup is complete:

# Clear and rebuild all compiled routes, configs, and Blade views
php artisan optimize
Documentation
⚡ 3-Minute Quick Start 1. Introduction & Overview 2. Server Requirements 3. Installation Guide 4. License Activation 5. Dashboard Telemetry 6. Media Manager 7. Catalog Management 8. Products Management 9. Orders & Fulfillment 10. Couriers & Shipping Costs 11. Coupons & Marketing 12. Payment Gateways 13. Theme Layouts Hub 14. Navigation & Mega Menus 15. Sliders & Banners 16. Pages, FAQ & About 17. Blogs & Editorial 18. Reviews & Messages 19. Team Members & Staff Roles 20. Locations & Coverage 21. System Settings Hub 22. Web Cron & FAQs 23. Extra Security & Speed Boost