Host Configuration

Product-specific configuration for PVE, PBS, and PMG

The enhanced host configuration system provides product-specific settings for Proxmox VE, PBS, and PMG.

Supported Products

Proxmox VE

Virtual Environment

PVE
Proxmox Backup Server

Backup Solution

PBS
Proxmox Mail Gateway

Email Security

PMG

Proxmox VE Configuration

PVE Settings
Storage Locations
  • ISO Storage: Where ISO images are stored (e.g., local)
  • Template Storage: Container templates location
  • Backup Storage: Backup destination
  • VM Storage: VM disk storage (e.g., local-lvm)
Resource Limits
  • Max VMs: Maximum number of VMs (0 = unlimited)
  • Max Containers: Maximum number of LXC containers (0 = unlimited)
SDN/IPAM Settings
  • Use SDN: Enable Software Defined Networking
  • SDN Zone: Default SDN zone name
  • Allowed Ports: Comma-separated port ranges (e.g., 80,443,8080-8090)

Proxmox Backup Server Configuration

PBS Settings
Datastore Configuration
  • Datastore Name: Name of the backup datastore
Retention Policy
  • Keep Daily: Number of daily backups to keep
  • Keep Weekly: Number of weekly backups to keep
  • Keep Monthly: Number of monthly backups to keep
Prune Schedule
  • Prune Schedule: Cron format (e.g., 0 2 * * * for daily at 2 AM)

Proxmox Mail Gateway Configuration

PMG Settings
Relay Settings
  • Relay Host: SMTP relay server hostname
  • Relay Port: SMTP port (default: 25)
Spam & Virus Protection
  • Spam Threshold: Score threshold (1-10)
  • Virus Scanning: Enable/disable virus scanning
  • Greylisting: Enable/disable greylisting

Adding a Host

Step-by-Step Guide
  1. Navigate to /admin/hosts/create
  2. Fill in basic information:
    • Display Name
    • Product Type (PVE/PBS/PMG)
    • Hostname/IP
    • Port (default: 8006)
  3. Enter API credentials:
    • API Token ID (e.g., root@pam!dashboard)
    • API Token Secret
  4. Configure product-specific settings (form updates automatically)
  5. Click "Add Host"

Database Schema

Tables
proxmox_hosts

Basic host information

id, name, type, hostname, port, api_token_id, api_token_secret, created_at
host_config

Extended product-specific configuration

id, host_id, public_ip, notes, iso_storage, template_storage, backup_storage, 
vm_storage, max_vms, max_lxc, use_sdn, sdn_zone, allowed_ports, datastore_name, 
prune_schedule, relay_host, relay_port, spam_threshold, virus_scanning, 
greylisting, created_at, updated_at
storage_locations

PVE storage mapping

id, host_id, storage_name, storage_type, path, content_types, created_at
ip_pool_config

IP pool configuration for hosts

id, host_id, pool_name, gateway, netmask, vlan_tag, created_at

API Routes

GET  /admin/hosts           - List all hosts
GET  /admin/hosts/create   - Create form
POST /admin/hosts/store    - Save new host
GET  /admin/hosts/edit?id=X - Edit form
POST /admin/hosts/update   - Update host
POST /admin/hosts/delete   - Delete host
POST /admin/hosts/sync     - Sync VMs from PVE host

Dynamic Form Behavior

JavaScript Form Switching

The host create/edit forms automatically show/hide product-specific sections based on the selected product type:

  • Select Proxmox VE → Shows PVE configuration section
  • Select Proxmox Backup Server → Shows PBS configuration section
  • Select Proxmox Mail Gateway → Shows PMG configuration section

This ensures users only see relevant fields for their selected product.