Posts

Showing posts with the label Jenkins Plugins

Add Build Parameter In Jenkins Build Schedule

Answer : Basically, with the 'Build periodically' option you can't schedule a Jenkins job with parameters. However, to schedule a job at different times that needs to use different environments, you have to use the parameterized-scheduler plugin or search for it in (Manage Jenkins -> Manage Plugins -> Parameterized Scheduler). Examples: # Parameter1 H/15 * * * * %Parameter1 # Parameter2 H/30 * * * * %Parameter2 Remember you have to have your parameters already setup because the plugin is visible only for jobs with parameters. The Node and Label parameter plugin can help since it allows you to select individual nodes assuming your different servers qa1 and qa2 are already configured. Hope that clarifies things for you. With the native Jenkins crontab, it's not possible. But it should be possible with this plugin: https://github.com/jwmach1/parameterized-scheduler You have to fork the repo and build this plugin + do a manual installation. Th...

Archive Artifacts In Jenkins

Answer : You cannot remove the 'prefix' of a path using just the archive artifacts setting. (Some of the upload extensions do support this - the Publish over FTP plugin for example) If you really need this a simple solution is to add an extra build step that copies your Debug folder to the root of the project workspace. A cleaner way might be to have a stage dedicated to producing artifacts, set up with the appropriate working directory: stage('Release') { steps { dir('MyApp1/MyApp1/bin/Debug') { archiveArtifacts artifacts: '**', fingerprint: true } } }