Sha256: 4ea138358dc1f9a28c5c46d120f53288d94fb56794f9df629092d0f9526472ef

Contents?: true

Size: 1.04 KB

Versions: 9

Compression:

Stored size: 1.04 KB

Contents

require 'chef/provisioning'
require 'chef/provisioning/vsphere_driver'

#
# This is the main way to connect to vSphere
#
with_vsphere_driver host: '172.16.20.2',
  insecure: true,
  user:     'administrator@vsphere.local',
  password: 'PASSWORD'

#
# These are the machine_options that you need to declare
#
with_machine_options :bootstrap_options => {
                               num_cpus: 2,
                               memory_mb: 4096,
                               datacenter: 'Datacenter',
                               resource_pool: 'Cluster',
                               template_folder: 'Linux',
                               template_name: 'ubuntu16',
                               :ssh => {
                                 :user => 'admini',
                                 :password => 'PASSWORD',
                                 :paranoid => false,
                               }
                             },
                :sudo => true

#
# This is where you can declare the machine
#
machine "testing-ubuntu" do
  tag "haha"
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
chef-provisioning-vsphere-2.2.2 examples/ubuntu-provision.rb
chef-provisioning-vsphere-2.2.1 examples/ubuntu-provision.rb
chef-provisioning-vsphere-2.2.0 examples/ubuntu-provision.rb
chef-provisioning-vsphere-2.1.0 examples/ubuntu-provision.rb
chef-provisioning-vsphere-2.0.10 examples/ubuntu-provision.rb
chef-provisioning-vsphere-2.0.9 examples/ubuntu-provision.rb
chef-provisioning-vsphere-2.0.8 examples/ubuntu-provision.rb
chef-provisioning-vsphere-2.0.7 examples/ubuntu-provision.rb
chef-provisioning-vsphere-2.0.6 examples/ubuntu-provision.rb