Vagrant file to bring up VM using Puppet

0 votes
I'm trying to provision a VM using vagrant and puppet. How should my vagrant file look?
Mar 12 in Puppet by Nisha
30 views

1 answer to this question.

0 votes

You vagrant file should look something like this, make the required.

config.vm.define "db" do |db|   
  db.vm.hostname = "db"    
  db.vm.network "private_network", ip: "10.11.1.201", virtualbox__intnet: true
  db.vm.provider "virtualbox" do |v| 
      v.memory = 1024 
  end 

  db.vm.network "forwarded_port", guest: 22, host: 2221, id: 'ssh', auto_correct: true
    db.vm.network "forwarded_port", guest: 5432, host: 2222
  db.ssh.forward_agent = true

       config.vm.provision :shell do |shell|
 shell.inline = "mkdir -p /etc/puppet/modules;
                 puppet module install puppetlabs-postgresql"

  end
       config.vm.provision :puppet do |puppet|
    puppet.manifests_path = "puppet/manifests"
    puppet.manifest_file = "site.pp"
    puppet.module_path = "puppet/modules"
  end
    end
end
answered Mar 12 by Barbara

Related Questions In Puppet

+5 votes
2 answers

How To Deploy Windows Server Using Puppet?

Deploying windows server through Puppet is similar ...READ MORE

answered Mar 26, 2018 in Puppet by shubham
• 6,890 points
282 views
0 votes
1 answer
0 votes
1 answer

Error while trying to instal mssql tools using puppet

When you use puppet, you don't use ...READ MORE

answered Feb 25 in Puppet by Nandita
92 views
+13 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 26, 2018 in DevOps & Agile by DragonLord999
• 8,380 points
152 views
0 votes
1 answer
0 votes
0 answers
0 votes
1 answer

Puppet+Kubernetes: Should i install Docker inorder to start using puppetlabs/kubernetes module?

The puppetlabs/kubernetes module installs and configures Kubernetes. You need ...READ MORE

answered Aug 23 in Puppet by Sirajul
• 25,700 points
17 views