Skip to content

Deployment Overview of Proxmox 9 on Server

Prerequisites and Basic Requirements

To ensure a successful deployment, the following requirements must be met:

  • Operating System: Debian (versions 11 Bullseye, 12 Bookworm, or 13 Trixie are supported).

  • Privileges: Root or sudo access is required for all installation steps.

  • Network Requirements:

  • Access to the internet to download packages and Docker images.

  • Port 8006 must be available for internal application traffic.

  • Port 443 (HTTPS) must be open for external web access via Nginx.

FQDN of the final panel on the hostkey.in domain

The application is configured to use a specific subdomain based on the server ID.

Parameter Value
Prefix proxmox
Domain hostkey.in
Full template proxmox{Server_ID_from_Invapi}.hostkey.in

File and Directory Structure

The following directories are created or utilized during the deployment process:

  • /root/nginx: Contains the Docker Compose configuration for the Nginx proxy.

  • /data/nginx/user_conf.d/: Stores custom Nginx configuration files, including the specific site configuration for Proxmox.

  • /data/nginx/letsencrypt/.well-known/acme-challenge: Used by Certbot for SSL certificate validation via the webroot method.

  • /data/nginx/nginx-certbot.env: Configuration file containing environment variables for the Nginx container (e.g., RENEWAL_INTERVAL).

Application installation process

The installation of Proxmox VE is performed through a series of system-level configuration steps and package installations:

  1. System Preparation: The installer configures the GRUB bootloader to target the correct root disk and disables the enterprise repository to allow for standard updates.

  2. Repository Configuration: A non-subscription Proxmox VE repository is added to the APT sources, and the corresponding GPG security keys are installed.

  3. Kernel Installation: Depending on the Debian version, a specific Proxmox kernel is installed:

  4. For Debian 11: pve-kernel-5.15

  5. For Debian 12/13: proxmox-default-kernel

  6. Cleanup: The standard Debian kernels are removed to ensure the system boots exclusively using the Proxmox kernel.

  7. Core Application Installation: The following packages are installed via the package manager:

  8. proxmox-ve

  9. postfix

  10. open-iscsi

  11. System Services: chrony is installed for time synchronization (on Debian 12+), and debconf-utils and isc-dhcp-client are added to support the installation process.

Access Rights and Security

  • Firewall: The system relies on standard host security; ensure that only necessary ports (443 for HTTPS) are exposed externally.

  • GRUB Configuration: os-prober is removed from the system to prevent unauthorized bootloader entries.

  • Docker Security: A custom docker.service configuration is applied to enable proper cgroup delegation, ensuring container resource management functions correctly.

Databases

No separate database server is installed as part of this specific deployment; Proxmox utilizes its own internal storage mechanisms for cluster and VM data.

Docker Containers and Their Deployment

The deployment includes a specialized Nginx container used for reverse proxying and SSL management via Docker Compose.

Nginx-Certbot Container

  • Image: jonasal/nginx-certbot:latest

  • Ports: Uses network_mode: host to bind directly to the host's network interface.

  • Volumes:

  • nginx_secrets:/etc/letsencrypt: Stores SSL certificates (external volume).

  • /data/nginx/user_conf.d:/etc/nginx/user_conf.d: Mounts custom site configurations.

  • /data/nginx/letsencrypt:/var/www/letsencrypt: Provides the webroot for ACME challenges.

  • Environment Variables:

  • [email protected]

  • Loaded from /data/nginx/nginx-certbot.env.

  • Restart Policy: unless-stopped

Custom Scripts and Additional Setup

The installation performs several automated configuration tasks:

  • Nginx Configuration Patching: A Python script is executed to automatically modify the Nginx site configuration. It injects an ACME challenge location block for Let's Encrypt and configures the proxy_pass directive to point to https://127.0.0.1:8006 with necessary SSL verification settings (proxy_ssl_server_name on; proxy_ssl_verify off;).

  • Hostname Setup: The system hostname is automatically set to match the defined domain template.

  • Hosts Entry: An entry is added to /etc/hosts mapping the server's IP address to its local service name.

Application Update Instructions

To update the main application, perform a full system upgrade via the package manager:

apt update && apt full-upgrade -y

For the Nginx proxy container, use the following command in the /root/nginx directory:

docker compose pull && docker compose up -d

Location of configuration files and data

Type Path
Nginx Compose File /root/nginx/compose.yml
Nginx Site Configs /data/nginx/user_conf.d/
SSL Certificates Managed via nginx_secrets volume
Environment Variables /data/nginx/nginx-certbot.env

Available ports for connection

  • 443 (TCP): External HTTPS access to the Proxmox web interface via Nginx proxy.

  • 8006 (TCP): Internal Proxmox management interface.

Starting and Stopping the application

The primary service is managed through systemd. To manage the Docker engine, use:

systemctl start docker
systemctl stop docker

To manage the Nginx proxy container:

cd /root/nginx
docker compose up -d
docker compose down

Proxy Servers

The deployment utilizes an Nginx container running in host network mode. This container acts as a reverse proxy, handling SSL termination via Let's Encrypt and forwarding traffic to the Proxmox service running on port 8006. It is configured to automatically handle ACME challenges through a dedicated webroot directory.

question_mark
Is there anything I can help you with?
question_mark
AI Assistant ×