I am able to do that by using 
config.vm.network  "public_network", bridge: 'eth1', ip: "172.16.72.246"

On Wednesday, 13 January 2016 10:06:36 UTC, govind parashar wrote:
>
> Hello
>
> I have centos7 machine, which is on my local LAN. This machine IP is 
> 172.16.72.245, In this I have installed vagrant and virtualBox on the same. 
> I have written  vagrant file which contains below code to create a VM. I 
> need to assign static IP i.e. 172.16.72.246 to new VM, Please suggest me 
> how do it.
>
> Code Snippet
>
> Vagrant.configure(2) do |config| 
>   config.vm.box = "vStone/centos-7.x-puppet.3.x"
>   config.vm.hostname = "Jenkins-box"
>   config.vm.box_check_update = false
>   config.vm.network "private_network", ip: "172.16.72.246"
>   config.vm.synced_folder "../../", "/vshare/", create: true
>   
>   config.vm.provider "virtualbox" do |vb|
>     vb.memory = "2048"
>     vb.cpus = "1"
>   end
> end
>
>
>
>
>  
>

-- 
This mailing list is governed under the HashiCorp Community Guidelines - 
https://www.hashicorp.com/community-guidelines.html. Behavior in violation of 
those guidelines may result in your removal from this mailing list.

GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
--- 
You received this message because you are subscribed to the Google Groups 
"Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vagrant-up/fd01cbb2-6547-4035-950a-220e4833d8ef%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to