Giter Club home page Giter Club logo

esxi-playground's Introduction

ESXi playground

This Vagrantfile gives you a little playground to get started with ESXi 6.0.0 and the vSphere Client.

Vagrant boxes

esxi60

The basebox must be build with the packer-esxi repo. Add an ESXi 6.0 box with the name esxi60.

After starting up the Vagrant box have a look at the IP address of the ESXi server.

esxi60

win7

The basebox must be build with the packer-windows repo. Add a Windows 7 box with the name windows_7.

After starting up the Vagrant box the VMware vSphere Client 6.0.0 will be installed.

Connect with it to your ESXi server to 192.168.254.135 and user root and password vagrant.

win7

Install Vagrant plugin

To provision the ESXi Vagrant box you have to install the Vagrant ESXi plugin:

vagrant plugin install vagrant-esxi

Build the boxes

Just create the two Vagrant boxes with

vagrant up --provider vmware_fusion

Create a Docker machine on the ESXi server

You can create a Docker host with docker-machine on the ESXi server. Use the create-docker-esxi.sh script and adjust the IP address of your ESXi VM.

docker-machine --debug create -d vmwarevsphere \
  --vmwarevsphere-vcenter="192.168.254.133" \
  --vmwarevsphere-username="root" \
  --vmwarevsphere-password="vagrant" \
  --vmwarevsphere-network="VM Network" \
  --vmwarevsphere-datastore="datastore1" \
  --vmwarevsphere-datacenter="ha-datacenter" \
  dockervm0

You will need docker-machine and govc in your PATH. See https://docs.docker.com/machine/ for more details.

Notice: The docker-machine driver does not work with the free ESXi license, but you can try it in the 60 day trial period without inserting the license.

Create a Vagrant box inside the ESXi server

Go into the packer/ubuntu sub directory and build this basebox with packer and your just created ESXi server. This could be done from your host machine, in my case a MacBook Pro.

Just set the IP address as variable so packer can connect to your ESXi server.

cd packer/ubuntu
packer build -var 'remote_host=192.168.254.135' ubuntu1404-desktop-esx.json

This Ubuntu basebox is the work of all the Box-Cutter maintainers and contributors. You can find the original repo at https://github.com/boxcutter/ubuntu.

Run a Vagrant box in ESXi server

Go to the win7 Box and open up a PowerShell console. The vagrant plugin vagrant-esxi is a work in progress. This example is just a proof of concept to show that it is possible to power on VM's in ESXi with Vagrant.

cd c:\vagrant\vagrant
vagrant up

esxi-playground's People

Contributors

stefanscherer avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

cromatido myang32

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.