{"id":18445753,"url":"https://github.com/voronenko/instancegarden","last_synced_at":"2026-03-19T04:25:55.140Z","repository":{"id":46814733,"uuid":"56502751","full_name":"Voronenko/instancegarden","owner":"Voronenko","description":"Set of starters to test stuff in vagrant or ESXi","archived":false,"fork":false,"pushed_at":"2023-03-08T11:31:19.000Z","size":187,"stargazers_count":1,"open_issues_count":8,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-15T01:16:00.623Z","etag":null,"topics":["esxi","vagramt"],"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/Voronenko.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":"2016-04-18T11:37:08.000Z","updated_at":"2023-03-08T11:31:25.000Z","dependencies_parsed_at":"2025-02-16T12:25:59.250Z","dependency_job_id":"66876738-04a0-406f-b2c4-ccf011e81fe0","html_url":"https://github.com/Voronenko/instancegarden","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/Voronenko%2Finstancegarden","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Voronenko%2Finstancegarden/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Voronenko%2Finstancegarden/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Voronenko%2Finstancegarden/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Voronenko","download_url":"https://codeload.github.com/Voronenko/instancegarden/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248986315,"owners_count":21194025,"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","vagramt"],"created_at":"2024-11-06T07:07:08.869Z","updated_at":"2026-01-23T00:57:24.541Z","avatar_url":"https://github.com/Voronenko.png","language":"HCL","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Vagrant boxes matrix\n\n| OS  | IP  | Hostupdater alias  |   |\n|---|---|---|---|\n| ubuntu/bionic | 192.168.55.103  | bionic.vagrant.voronenko.net |\n|   |   |   |   |\n|   |   |   |   |\n|   |   |   |   |\n|   |   |   |   |\n|   |   |   |   |\n|   |   |   |   |\n|   |   |   |   |\n|   |   |   |   |\n\n\n\nFor better experience add to `/etc/sudoers.d/YOURUSER` replacing slavko with your username\n\n```\n#slavko ALL=(ALL) NOPASSWD: ALL\n\n# vagrant-hostsupdater\nCmnd_Alias VAGRANT_HOSTS_ADD = /bin/sh -c echo \"*\" \u003e\u003e /etc/hosts\nCmnd_Alias VAGRANT_HOSTS_REMOVE = /usr/bin/sed -i -e /*/ d /etc/hosts\nslavko ALL=(root) NOPASSWD: VAGRANT_HOSTS_ADD, VAGRANT_HOSTS_REMOVE\n\n# vagrant-nfs\nCmnd_Alias VAGRANT_EXPORTS_ADD = /usr/bin/tee -a /etc/exports\nCmnd_Alias VAGRANT_NFSD = /sbin/nfsd restart\nCmnd_Alias VAGRANT_EXPORTS_REMOVE = /usr/bin/sed -E -e /*/ d -ibak /etc/exports\nslavko ALL=(root) NOPASSWD: VAGRANT_EXPORTS_ADD, VAGRANT_NFSD, VAGRANT_EXPORTS_REMOVE\n\nslavko ALL=(ALL) NOPASSWD: /usr/bin/truecrypt\nslavko ALL=(ALL) NOPASSWD: /bin/systemctl\nslavko ALL=(ALL) NOPASSWD: /sbin/poweroff, /sbin/reboot, /sbin/shutdown\nslavko ALL=(ALL) NOPASSWD: /etc/init.d/nginx, /etc/init.d/mysql, /etc/init.d/mongod, /etc/init.d/redis, /etc/init.d/php-fpm, /usr/bin/pritunl-client-pk-start\nslavko ALL=(ALL) NOPASSWD:SETENV: /usr/bin/docker, /usr/sbin/docker-gc, /usr/bin/vagrant\n\n```\n\n\n# cloud-init perks\n\nPassword can be created with\n\n```\nopenssl passwd -1 -salt SaltSalt secret\n```\n\nexample\n\n```\nopenssl passwd -1 -salt slavko Passw0rd1\n$1$slavko$mhTAXUOoJfrnQeSlO2AVR.\n```\n\n# ESXi notes\n\nesxcli:   https://my.vmware.com/group/vmware/get-download?downloadGroup=ESXCLI-67U2\n\nFor ESXi following cloud-init package needs to be installed\n\nhttps://github.com/vmware/cloud-init-vmware-guestinfo\n\n## Dealing with naked centos-es\n\nCheck adapters\n\n```\nnmcli d\n```\n\nif exist, type “nmtui” command in your terminal to open Network manager. After opening Network manager chose “Edit connection” \n\n\nAfter activated,  use \n```\nip a\n```\n\nto validate, that address was really assigned.\n\nIf you are going to use that image as further ESXi template,\nconsider installing vmware cloud init \n\n```\ncurl -L -O ./cloudinit.rpm https://bit.ly/esxi-cloud-init\nyum install ./cloudinit.rpm\n```\n\ntarget machine can be exported as ova template using\n\n```\novftool vi://$GOVC_USERNAME:$GOVC_PASSWORD@$GOVC_URL/VMNAME ./\n```\n\ntarget output can be packed into OVA image using \n\n```\ntar -cvf centos7.ova *.ovf *.vmdk *.nvram *.mf\n```\n\nNote: order ovf, vmdk, nvram mf might be important\n\n## ESXi terraform-provider-esxi plugin\n\nI am using patched version of the great terraform-provider-esxi by https://github.com/josenk/terraform-provider-esxi\nMy original PR was slightly modified by author, and in a current master solution does not work (at least for me)\n\nI have that in a backlog, but until that I am sticking to my version 1.5.4bis\n\nhttps://github.com/Voronenko/terraform-provider-esxi/tree/1.5.4.bis \n\nwhich works nicely on my HomeLab environment\n\n\n## ESXi and windows\n\nUnless `ovftool --hideEula YourWindows.ova` shows you some useful properties for auto provisioning,\nyou will need to configure your virtual windows for provisioning manually\n\n```powershell\n# VMWare tools\nchoco install vmware-tools\n\n# WinFiles\nSet-ExecutionPolicy Bypass -Scope Process -Force; \niex ((New-Object System.Net.WebClient).DownloadString('https://bit.ly/winfiles'))\n\n# Ansible Remoting\nSet-ExecutionPolicy Bypass -Scope Process -Force; iex ((New-Object System.Net.WebClient).DownloadString('https://bit.ly/ansible_remoting'))\n\n# Optional, enable remote desktop if it is disabled for some reason\nSet-ItemProperty -Path 'HKLM:SystemCurrentControlSetControlTerminal Server'-name \"fDenyTSConnections\" -Value 0\nEnable-NetFirewallRule -DisplayGroup \"Remote Desktop\"\n```\n\n\n# Inconsistent vms\n\n\nConnect to the ESXi host using SSH client (Putty, mputty, etc.);\n\nTo get the ID of the problem virtual machine, run this command: \n\n```\nvim-cmd vmsvc/getallvms | grep invalid\n```\n\nA list of all VMs with the Invalid status registered on this host will be displayed. \nThere should be a string like: Skipping invalid VM '22'. In this case, 22 is the ID of the virtual machine;\n\nIf you want to try and restore this VM in vSphere, run the command: vim-cmd vmsvc/reload 22 (in a minute refresh the client interface and check the VM status);\n\nIf you want to unregister (delete) a problem virtual machine, run the following command: vim-cmd /vmsvc/unregister 22\n\n\n# Trusted vms\n\n\nAllow logging in with your current key\n\n```\n    config.vm.provision \"shell\" do |s|\n      ssh_pub_key = File.readlines(\"#{Dir.home}/.ssh/id_rsa.pub\").first.strip\n      s.inline = \u003c\u003c-SHELL\n        echo #{ssh_pub_key} \u003e\u003e /home/vagrant/.ssh/authorized_keys\n        echo #{ssh_pub_key} \u003e\u003e /root/.ssh/authorized_keys\n      SHELL\n    end\n```\n\nInject your own key into vm\n\n```\nconfig.vm.provision \"file\", source: \"#{Dir.home}/.ssh/id_rsa\", destination: \"/home/vagrant/.ssh/id_rsa\"\n```\n\n\n## Enabling keyboard between ESXi remote console and  host\n\nEnable content Copy/Paste between VMRC client and Windows/Linux Virtual Machine (57122)\nhttps://kb.vmware.com/s/article/57122\n\nInstall or upgrade the VMware tools for the Windows/Linux virtual machine(VM). For more information see Installing and upgrading VMware Tools in vSphere.\n\nPower off the VM.\n\nGoto  Edit Settings =\u003e Advanced =\u003e Edit Configuration\nSpecify\n\n```\nName:                                 Value:\nisolation.tools.copy.disable          FALSE\nisolation.tools.paste.disable         FALSE\nisolation.tools.setGUIOptions.enable  TRUE\n```\n \n​These options override any settings made in the guest operating system’s VMware Tools control panel\n \nThen use Copy/Paste directly on Windows/Linux/any other platform. \nFor paste operation's target platform is Linux, Older X applications do not use a clipboard. Instead, they let you paste the currently selected text (called the \"primary selection\") without copying it to a clipboard. Pressing the middle mouse button is usually the way to paste the primary selection. For more information see Copying and pasting from a Windows guest to Linux host.\n\nNOTE: This Steps provided in the kb helps you to copy the data not file/folder. This is per VM level configuration.\n\n\n## Autologin for windows dummy boxes\n\nAssuming your image has pin,fingerprint login not activated, you can use\n\n```sh\nNetplwiz\n```\n\nand uncheck button \"require username and password\".  In that scenario in your home garden you get additional 15-20 secs to start working with lab instance.\n\nIf you have sysinternals installed, there os also sysinternals utility\n\nhttps://docs.microsoft.com/en-us/sysinternals/downloads/autologon\n\n## Working in ESXi using vmrc\n\nIn my scenario I was constantly getting keyboard in misconfigured state on return from client, which forced me\nto put a custom shortcut running\n\n```\nsetxkbmap\n```\n\nwhich resets keyboard to a proper state\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvoronenko%2Finstancegarden","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvoronenko%2Finstancegarden","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvoronenko%2Finstancegarden/lists"}