Where should the testing files be located to run puppet-parser-validate puppet-lint against pp in a Jenkins Puppet setup

0 votes
I need to run puppet-parser-validate, and puppet-lint on my existing puppet infrastructure, aboard I actually have a Jenkins server and have organized a Jenkins job that is triggered by a gitlab push.
The project structure is as follows:
puppet
--certs
--environments
----beta0-10
----production
----staging
--json
--manifests
--modules
----builds
----master
----node
--scripts
I have no idea as to where the testing files should be located to run puppet-parser-validate/puppet-lint against *.pp. Can somebody please help me with this?
Aug 8, 2019 in Puppet by anonymous
• 19,610 points
892 views

1 answer to this question.

0 votes
  • Rake is sophisticated test runner written in Ruby and is a standard way of running test. You can do it with help of systems such as Rake. 

  • You can see example of Rake files when you generate new Puppet module with puppet module generate companyname-modulename command. 

  • In root directory of your project you will find Rakefile where you will see default configuration. 

  • In default configuration you can see that validation task is already done and ready to use. Just make sure that paths are all good.

  • To run validation task you need to make sure that gems mentioned in Gemfile are installed. You can do it with bundle install

  • To run validation task just run bundle exec rake validate.

    Source: StackOverflow.

answered Aug 8, 2019 by Sirajul
• 59,230 points

Related Questions In Puppet

+1 vote
1 answer

I am running a Jenkins job to sign the certificate by puppet master but it is failing

Refer to https://www.edureka.co/community/55971/puppet-error-while-signing-the-certificates This addresses a similar query like ...READ MORE

answered Mar 13, 2020 in Puppet by Liana
1,298 views
0 votes
1 answer

How to install a package in the slave node with Puppet ?

Hi@akhtar, You need to add your node definition ...READ MORE

answered Dec 31, 2020 in Puppet by MD
• 95,460 points
1,325 views
0 votes
1 answer

How to change the run interval time in puppet?

Hi@akhtar, You can change the run interval time ...READ MORE

answered Dec 31, 2020 in Puppet by MD
• 95,460 points
1,599 views
0 votes
1 answer

Is it possible to install puppet agent in a docker container on linux?

Hey @Janice, this is pretty simple. Create ...READ MORE

answered Mar 12, 2019 in Puppet by Jason
1,530 views
+15 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 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
4,063 views
+2 votes
1 answer
0 votes
1 answer

How to change the run interval in puppet?

To check the run interval run the following ...READ MORE

answered Jul 29, 2019 in Puppet by Sirajul
• 59,230 points
3,726 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP