Environment Requirements¶
Platform¶
The project is tested on the following platforms:
Platform | Version |
VMware vSphere | 8.0 or later |
VMware vSphere | 7.0 Update 3D or later |
Operating Systems¶
The project is tested on the following operating systems for the Packer host 1 :
Operating System | Version | Architecture |
VMware Photon OS | 5.0 | x86_64 |
Ubuntu Server | 22.04 LTS | x86_64 |
macOS | Sonoma | Intel or Apple Silicon |
Packer¶
Installation¶
You can install Packer on VMware Photon OS using the following commands:
export PACKER_VERSION="1.11.0"
export OS_PACKAGES="wget unzip"
tdnf install ${OS_PACKAGES} -y
wget -q https://releases.hashicorp.com/packer/${PACKER_VERSION}/packer_${PACKER_VERSION}_linux_amd64.zip
unzip -o -d /usr/local/bin/ packer_${PACKER_VERSION}_linux_amd64.zip
You can install Packer on Ubuntu using the following commands:.
-
Configure the repository:
sudo bash -c 'wget -O- https://apt.releases.hashicorp.com/gpg | gpg --dearmor > /usr/share/keyrings/hashicorp-archive-keyring.gpg'
-
Verify the fingerprint:
gpg --no-default-keyring --keyring /usr/share/keyrings/hashicorp-archive-keyring.gpg --fingerprint
You can verify that the fingerprint matches the HashiCorp public key published on Security at HashiCorp.
-
Add the official HashiCorp repository to your system:
sudo bash -c 'echo "deb [signed-by=/usr/share/keyrings/hashicorp-archive-keyring.gpg] \ https://apt.releases.hashicorp.com $(lsb_release -cs) main" > /etc/apt/sources.list.d/hashicorp.list'
-
Install Packer from the HashiCorp repository:
sudo apt update && sudo apt install packer
You can install Packer on macOS using Homebrew.
brew tap hashicorp/tap
brew install hashicorp/tap/packer
Required plugins are automatically downloaded and initialized when using ./build.sh
.
For disconnected sites you may download the plugins and place these same directory as your Packer
executable /usr/local/bin
or $HOME/.packer.d/plugins
.
Additional Packages¶
The following additional software packages must be installed on the operating system running Packer.
Installation¶
Packages:
tdnf -y install ansible git jq xorriso wget unzip
echo "ansible-core $(ansible --version | grep 'ansible.*core' | awk '{print $3}' | tr -d ']')"
echo "terraform $(terraform version | awk -Fv '{print $2}' | head -n 1)"
export PATH="$HOME/.local/bin:$PATH"
Terraform:
export TERRAFORM_VERSION="1.9.5"
wget -q https://releases.hashicorp.com/terraform/${TERRAFORM_VERSION}/terraform_${TERRAFORM_VERSION}_linux_amd64.zip
unzip -o -d /usr/local/bin/ terraform_${TERRAFORM_VERSION}_linux_${LINUX_ARCH}.zip
Gomplate
export GOMPLATE_VERSION="3.11.7"
wget -q https://github.com/hairyhenderson/gomplate/releases/download/v${GOMPLATE_VERSION}/gomplate_linux-amd64
chmod +x gomplate_linux-amd64
sudo mv gomplate_linux-amd64 /usr/local/bin/gomplate
Packages:
sudo apt update
sudo apt install software-properties-common
sudo add-apt-repository --yes --update ppa:ansible/ansible
sudo apt install -y python3 python3-pip ansible git jq xorriso whois unzip
echo "ansible-core $(ansible --version | grep 'ansible.*core' | awk '{print $3}' | tr -d ']')"
echo "terraform $(terraform version | awk -Fv '{print $2}' | head -n 1)"
export PATH="$HOME/.local/bin:$PATH"
Gomplate:
export GOMPLATE_VERSION="3.11.7"
wget -q https://github.com/hairyhenderson/gomplate/releases/download/v${GOMPLATE_VERSION}/gomplate_linux-amd64
chmod +x gomplate_linux-amd64
sudo mv gomplate_linux-amd64 /usr/local/bin/gomplate
Packages
brew install ansible git jq coreutils hashicorp/tap/terraform gomplate
echo "ansible-core $(ansible --version | grep 'ansible.*core' | awk '{print $3}' | tr -d ']')"
echo "terraform $(terraform version | awk -Fv '{print $2}' | head -n 1)"
export PATH="$HOME/.local/bin:$PATH"
-
The project may work on other operating systems and versions, but has not been tested by the maintainers. ↩