Skip to content

v1.0.0-Packer Automation (2025-14-08)

Choose a tag to compare

@rtaparay rtaparay released this 20 Aug 05:30
· 11 commits to main since this release

Release Notes:

🚀 Features

  • Ubuntu Server 24.04 LTS : Automated creation of base VM templates using Ubuntu Server Noble
  • Proxmox Integration : Native support for Proxmox VE virtualization platform
  • Cloud-Init Support : Pre-configured cloud-init for automated VM initialization
  • Kubernetes Ready : Pre-configured firewall rules and network settings for Kubernetes deployment
  • QEMU Agent : Built-in QEMU guest agent for enhanced VM management
  • Automated Provisioning : Unattended installation with custom boot commands

🏗️ Infrastructure Components

  • Base Image Builder : Ubuntu Server 24.04 LTS template creation
  • Network Configuration : Virtio network adapter with bridge support
  • Storage Management : Virtio SCSI controller with qcow2 disk format
  • Security Hardening : Firewalld configuration with Kubernetes port management
  • Legacy Network Tools : iptables, arptables, and ebtables in legacy mode

📦 Template Specifications

  • Operating System : Ubuntu Server 24.04 LTS (Noble Numbat)
  • Virtualization : Proxmox VE with ISO-based installation
  • Storage : Configurable disk size with LVM storage pool support
  • Network : Virtio network model with customizable bridge configuration
  • Boot : Cloud-init enabled with HTTP-served autoinstall configuration

🔧 Configuration Features

  • Variable Management : Comprehensive variable system for environment customization
  • Security : Sensitive variables (API tokens, passwords) properly marked
  • Flexibility : Configurable VM specifications (CPU, RAM, storage, network)
  • Logging : Detailed build logs with timestamp support
  • Validation : Template validation before build execution

🔐 Pre-configured Security

  • Firewalld : Enabled by default with Kubernetes port configuration
  • Kubernetes Ports : Pre-opened ports for cluster communication
    • 6443/tcp: Kubernetes API Server
    • 2379-2380/tcp: etcd services
    • 10250/tcp: Kubelet API
    • 10251/tcp: kube-scheduler
    • 10252/tcp: kube-controller-manager
    • 10255/tcp: Kubelet read-only API

📋 Prerequisites

  • Proxmox VE with API access
  • Packer >= 1.8
  • API token with VM creation permissions
  • Ubuntu Server 24.04 LTS ISO in Proxmox storage

🚦 Getting Started

  1. Initialize Packer: packer init -upgrade .
  2. Configure variables in dev.pkrvars.hcl
  3. Validate template: packer validate -var-file=dev.pkrvars.hcl .
  4. Build image: packer build -var-file="dev.pkrvars.hcl" .
  5. Monitor with logs: PACKER_LOG=1 packer build -on-error=ask -var-file="dev.pkrvars.hcl" .

🛠️ Build Process

  • Automated Installation : Unattended Ubuntu Server installation
  • System Updates : Latest package updates and security patches
  • Network Tools : Legacy iptables configuration for Kubernetes compatibility
  • Firewall Setup : Pre-configured firewalld rules for cluster communication
  • Template Creation : Proxmox VM template ready for Terraform deployment

📊 Template Output

  • Format : qcow2 disk image
  • Agent : QEMU guest agent enabled
  • Cloud-Init : Ready for automated configuration
  • Network : Virtio network adapter configured
  • Storage : Virtio SCSI controller optimized

🔄 Integration

  • Terraform : Templates ready for VM provisioning
  • Ansible : Pre-configured for automated Kubernetes installation
  • CI/CD : Supports automated image building pipelines
  • Version Control : Template versioning and change tracking