Last active
August 29, 2015 14:27
-
-
Save jsmartt/74ffc5127fa459fa4979 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'chef/provisioning' | |
with_driver 'oneview' | |
machine 'web01' do | |
machine_options :driver_options => { | |
:server_template => 'Template - Web Server', | |
:os_build => 'CHEF-RHEL-6.5-x64', | |
:host_name => 'chef-web01', | |
:ip_address => 'xx.xx.xx.xx', | |
:domainType => 'workgroup', | |
:domainName => 'synergy.hp.com', | |
:mask => '255.255.255.0', # Can set here or in individual connections below | |
:dhcp => false, | |
:gateway => 'xx.xx.xx.1', | |
:dns => 'xx.xx.xx.xx,xx.xx.xx.xx,xx.xx.xx.xx', | |
:connections => { | |
1 => { :dhcp => true, :net => 'deadnet5', :deployNet => 'pxe5' }, | |
2 => { :dhcp => false, :ip4Address => '10.0.200.6', :net => 'dmz-prod' }, | |
3 => { :dhcp => false, :ip4Address => '10.0.100.6', :net => 'backend-prod' } | |
} | |
}, | |
:transport_options => { | |
:ssh_options => { | |
:password => Chef::Config.knife[:node_root_password] | |
} | |
}, | |
:convergence_options => { | |
:bootstrap_proxy => 'http://proxy.domain.com:8080' # Optional | |
} | |
recipe 'my_apache_webserver::default' | |
chef_environment '_default' | |
converge true | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment