{"id":21077431,"url":"https://github.com/mhmdio/packer-esxi-ssh","last_synced_at":"2026-01-02T07:07:42.615Z","repository":{"id":71895980,"uuid":"334399257","full_name":"mhmdio/packer-esxi-ssh","owner":"mhmdio","description":"Packer build on ESXi connected with SSH","archived":false,"fork":false,"pushed_at":"2021-01-30T11:55:35.000Z","size":62,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-10T23:18:55.845Z","etag":null,"topics":["esxi","packer","ssh","ubuntu"],"latest_commit_sha":null,"homepage":"","language":"HCL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mhmdio.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-01-30T11:44:36.000Z","updated_at":"2021-01-30T11:55:38.000Z","dependencies_parsed_at":null,"dependency_job_id":"0b886103-d88a-4169-b281-1bcf68f3ba2a","html_url":"https://github.com/mhmdio/packer-esxi-ssh","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mhmdio%2Fpacker-esxi-ssh","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mhmdio%2Fpacker-esxi-ssh/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mhmdio%2Fpacker-esxi-ssh/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mhmdio%2Fpacker-esxi-ssh/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mhmdio","download_url":"https://codeload.github.com/mhmdio/packer-esxi-ssh/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243521281,"owners_count":20304186,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["esxi","packer","ssh","ubuntu"],"created_at":"2024-11-19T19:36:41.673Z","updated_at":"2026-01-02T07:07:42.585Z","avatar_url":"https://github.com/mhmdio.png","language":"HCL","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Packer Build on VMware ESXi\n\n![packer](docs/packer-logo.png)\n\nUse Packer to build VM on ESXi 7.0u1\n\n- build machines directly on VMware vSphere Hypervisor using SSH (as opposed to the vSphere API)\n\n## Building Requirements\n\n- Packer\n- ovftool\n- ESXi host connectivity\n- ESXi host username and password with permission\n\n## ESXi Requirements\n\n- enable ssh\n- enable shell\n- run `esxcli system settings advanced set -o /Net/GuestIPHack -i 1`\n\n## Packer commands\n\n```bash\ncd OS_FOLDER\npacker fmt .        # Rewrites HCL2 config files to canonical format \npacker validate .   # check that a template is valid\npacker inspect .    # see components of a template\npacker build .      # build image(s) from template\n```\n\n## ovftool\n\nDownload from [here](https://my.vmware.com/group/vmware/downloads/details?downloadGroup=OVFTOOL441\u0026productId=742)\n\n### macOS\n\n```bash\nln -s /Applications/\"VMware OVF Tool\"/ovftool /usr/local/bin/ovftool\n```\n\n## Packer Templates\n\n- LTS -\u003e [linux-ubuntu-20.04](./linux-ubuntu-20.04/)\n- [linux-ubuntu-20.10](./linux-ubuntu-20.10/)\n- [linux-alpine](./linux-alpine/)\n\n## Troubleshoot\n\n- Networking: make sure VMs are getting IPv4 from DHCP.\n\n## References\n\n- (ubuntu autoinstall)[https://ubuntu.com/server/docs/install/autoinstall-reference]\n- (packer vmware-iso source)[https://www.packer.io/docs/builders/vmware/iso]\n\n## Generate Hash Password\n\nuser-data file (cloud-init) used hashed Password.\n\n```bash\nprintf vagrant | mkpasswd -m sha-512 -S vagrant. -s\n```\n\n## Packer autoinstall\n\nPacker autoinstall can be done with cloud-init by  passing meta-data and user-data with one of the following methods:\n\n- via CD drive, you need to pass `autoinstall ds=nocloud;seedfrom=/cidata/` [not all OS reqiure this]\n- via HTTP IP and HTTP Port, you need to pass `autoinstall ds=nocloud-net\\\\;s=http://{{.HTTPIP}}:{{.HTTPPort}}/`\n\n## Build\n\nPacker will generate OVA (OVF package) for each image in [build](./build) folder.\n\nTested import OVA on:\n\n- macOS - VMware Fusion\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmhmdio%2Fpacker-esxi-ssh","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmhmdio%2Fpacker-esxi-ssh","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmhmdio%2Fpacker-esxi-ssh/lists"}