Puppet and Jenkins: How can I manage Jenkins job using Puppet DSL?

0 votes

I have installed the rtyler/jenkins module in puppet to use jenkins with puppet. 

Can somebody tell me how do i manage jenkins jobs like create, remove etc using puppet DSL?

Aug 28, 2019 in Puppet by kriti
60 views

1 answer to this question.

0 votes

Managing Jenkins jobs:

Build jobs can be managed using the jenkins::job define

  • Creating or updating a build job:

jenkins::job { 'test-build-job':
  config => template("${templates}/test-build-job.xml.erb"),
}
  • Disabling a build job:

jenkins::job { 'test-build-job':
  enabled => 0,
  config  => template("${templates}/test-build-job.xml.erb"),
}
  • Removing an existing build job:

jenkins::job { 'test-build-job':
  ensure => 'absent',
}

answered Aug 28, 2019 by Sirajul
• 55,300 points

Related Questions In Puppet

0 votes
1 answer

How do I install factor and puppet using Ruby Gem?

Hey @Kiara, execute these commands to install ...READ MORE

answered Mar 8, 2019 in Puppet by Yogesh
295 views
0 votes
1 answer
0 votes
1 answer
+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,420 points
585 views
0 votes
1 answer
0 votes
1 answer

Can i install puppet master and puppet agent on the same centos machine? How will that work?

Yes, It's now possible to install both ...READ MORE

answered Aug 6, 2019 in Puppet by Sirajul
• 55,300 points
119 views
0 votes
1 answer

Puppet : Can i install jenkins on a puppet server using Git?

Installing puppet-jenkins is easy. To install via Git, ...READ MORE

answered Aug 9, 2019 in Puppet by Sirajul
• 55,300 points
79 views