Questions tagged [jenkins]

For questions about Jenkins, an open source automation server, and using Jenkins for topics such as building, testing, and deploying software, etc. For questions specifically about Jenkins Plugins use the jenkins-plugins tag.

Filter by
Sorted by
Tagged with
106 votes
6 answers
270k views

Cleanest way to prematurely exit a Jenkins Pipeline job as a success?

I have a job that will create files, unless one of the values being fed to it matches an older value. What's the cleanest way in Jenkins to abort or exit the job, without it being FAILED? It exiting ...
Alex's user avatar
  • 4,512
93 votes
5 answers
165k views

How to decrypt Jenkins passwords from credentials.xml?

I've taken over the project where a lot of Jenkins credentials has passwords or passphrase strings which I need to know in order to progress with the project, unfortunately these weren't documented ...
kenorb's user avatar
  • 7,821
74 votes
9 answers
141k views

How do you back up Jenkins jobs & master configs?

I'd like to backup all Jenkins jobs and config files. What's the easiest way of doing it?
kenorb's user avatar
  • 7,821
40 votes
7 answers
94k views

How to safe restart Jenkins?

I need to make some configuration changes on our Jenkins instance that will involve restarting Jenkins a couple of times. However, our developers are committing frequently enough that I haven't seen ...
Alex's user avatar
  • 4,512
35 votes
3 answers
87k views

How can we get the jenkins console output in a text file?

How can i get the Jenkins console output in a text file? I want to share it with someone, is there any way to do it?
Jay's user avatar
  • 964
33 votes
5 answers
62k views

How to properly achieve dynamic parallel action with a declarative pipeline?

Currently, I'm going to need an implementation that must find all files within a directory and start a parallel task for every file found. Is it possible to achieve this using declarative pipelines? ...
thclpr's user avatar
  • 831
32 votes
4 answers
10k views

How to properly scale Jenkins?

In my project we have one AWS server running Jenkins Master + 1 Jenkins slave (2 executors)... and we need more In order to augment our build power we have three options: Scale up: Make AWS instance ...
Oscar Foley's user avatar
28 votes
3 answers
33k views

Set a Jenkins job to not to clone the repo in SCM

I have integrated Jenkins with Bitbucket using the Bitbucket Plugin. As per the plugin's Wiki, a given job will be triggered if the repository is set in the SCM of the job. As you know, if one set SCM ...
Héctor Valverde's user avatar
28 votes
3 answers
42k views

How to build a complex parallel Jenkins pipeline?

I've been interested in converting our bespoke Jenkins integrations into a pipeline. However, I can't seem to figure out how to do it. Can anyone help me with the Jenkins script that could do the ...
Bert Goethals's user avatar
25 votes
3 answers
35k views

Jenkins Health Check URL

I'm planning to supervise services by periodically checking if they are up and running, Jenkins is our central orchestration tool and must be running with near zero downtime. How can I check health ...
storm's user avatar
  • 1,759
24 votes
2 answers
101k views

How to define variable in Jenkins declarative pipeline?

I defined variable in declarative Jenkins pipeline script but having issues with simple variable declaration. Here is my script: pipeline { agent none stages { stage("first") { ...
Jay's user avatar
  • 964
23 votes
3 answers
33k views

Running a background process in Pipeline job

I am looking for a way to run a java process in background using Jenkins declarative pipeline. Below is the snippet of code stage('Deploy'){ steps{ script{ withEnv(...
Dharanidhar's user avatar
23 votes
2 answers
24k views

Is it possible to upgrade Jenkins from Jenkins it-self?

On Manage Jenkins I've a message that: New version of Jenkins (2.47) is available for download (changelog). Is there any way of upgrading Jenkins from the GUI similar as it's done for the plugins? ...
kenorb's user avatar
  • 7,821
19 votes
3 answers
444 views

What are the advantages of using Jenkins over Hudson?

Jenkins is a fork of Hudson. What are the benefits/advantages of using Jenkins over Hudson for a small private business?
kenorb's user avatar
  • 7,821
18 votes
3 answers
6k views

Which SCM tools does Jenkins support?

I'm aware that Jenkins supports Git and SVN. What other SCM tools does Jenkins support?
kenorb's user avatar
  • 7,821
18 votes
4 answers
26k views

Best Practices for a multi environment deployment using Jenkins

I have 3 environments, each on their own Virtual Network with their own configurations. Do I need to have 3 separate instances of Jenkins if I am to do Continuous Deployments on each of the ...
Syed Shamikh Shabbir's user avatar
17 votes
4 answers
23k views

Jenkins: Permission issue using Docker as build environment

I installed Jenkins on an Ubuntu 16.04 machine. The Jenkins itself is not run in a container. What I want to do is simply call yarn install using a node image. So here is my Jenkinsfile: pipeline { ...
Michael's user avatar
  • 271
17 votes
1 answer
24k views

What is the difference between Jenkin's `Replay` and `Rebuild` options?

If you want to re-run a Jenkins job, you can click the Rebuild button which sometimes appears as the Replay button. What is the difference Rebuilding a job versus Replaying it? Why is it that some ...
Wimateeka's user avatar
  • 368
17 votes
2 answers
23k views

Triggering specific pipeline builds for monorepos in Jenkins

I'm in the process of converting multiple repositories into a single repository, our CI tool of choice is Jenkins due to the conversion of multiple repository structures into a single one 2 main ...
YellowPillow's user avatar
16 votes
3 answers
2k views

How to check AWS spot pricing automatically?

I've been thinking about a Jenkins job to check the pricing for the agent boxes we spin up; every so often the price spikes and it'll be an hour or two before anyone notices that no new agents are ...
Alex's user avatar
  • 4,512
16 votes
3 answers
18k views

One Jenkinsfile or multiple?

So I have a Jenkinsfile defining a build pipeline and then a Jenkins job (not pipeline) with a very simple deployment script for our Docker stacks. Seeing that Jenkinsfiles can become as complex and ...
Worp's user avatar
  • 679
14 votes
2 answers
22k views

How to check Jenkins build executor free memory?

In Jenkins when clicking on Build Executor Status I can only see free disk space related statistics (URI: /computer). How I can monitor free system memory (RAM) in Jenkins? I'm asking, because ...
kenorb's user avatar
  • 7,821
14 votes
2 answers
19k views

Get all change logs of since last successful build in Jenkins Pipeline

In my Jenkins pipeline, I can get change logs of the current build by this. def changeLogSets = currentBuild.changeSets Is there a way to get all change-logs since last successful build?
Bee's user avatar
  • 243
14 votes
2 answers
5k views

Is it bad to use sudo from Jenkins?

I use Publish Over SSH plugin to deploy my apps from Jenkins to different environments. Some deployment jobs do environment preps and things like stop and restart the app server system service. Some ...
amphibient's user avatar
14 votes
3 answers
10k views

How to not "fire and forget" when doing a remote trigger of a Jenkins build?

I am attempting to trigger a parameterized Jenkins build from Bamboo, doing the below: POST - http://jenkins-url.com/job/jobname/buildWithParameters?ENVIRONMENT=dev&APPLICATION=hello-world ...
osmorgan's user avatar
  • 309
14 votes
1 answer
3k views

Testing Jenkins jobs and pipelines

Currently, we have a fair number of Jenkins jobs and pipelines for builds, testing, deployments and other automated activities. Every time we change or add a new job, we only test it manually - e. g. ...
alecxe's user avatar
  • 849
14 votes
2 answers
28k views

How to enable the npm cache in a Jenkins build slave that runs in docker?

I have a Docker image, let's call it frontend.image, that I use for a Jenkins build slave. The Jenkins Docker plugin will spin up a container from this image and build artifacts inside the container. ...
Brian Ogden's user avatar
14 votes
3 answers
11k views

Using Artifactory plugin in Jenkins declarative pipeline

I am using Jenkins Declarative Pipeline to automate my build process. We want to publish our artifacts to a remote JFrog repository only if certain conditions (Sonar,Checkmarx) pass. After a bit of ...
Dharanidhar's user avatar
14 votes
3 answers
1k views

How do you test changes to Jenkins plugins before deploying them?

If you ever been bitten by a plugin upgrade that broke some functionality you must have given some thought about this problem: What should be the Jenkins plugins upgrade policy? How do you test ...
Michael Pereira's user avatar
13 votes
2 answers
354 views

Continuous Integration infrastructure for multiple iOS projects

As a iOS developer, I was looking to create a CI and CCQ (= Continuous Code Quality) infrastructure for the iOS projects we have in development so far. We already use Jenkins and SonarQube for almost ...
Dan Bodnar's user avatar
13 votes
3 answers
22k views

Jenkins vs Azure DevOps Pipelines

I've been doing some research on the Azure DevOps solution that Microsoft recently unveiled. Some background, I've been using Jenkins for years, and recently started exploring the containerisation ...
Anrich's user avatar
  • 182
13 votes
4 answers
3k views

Which plugin should I use to get started with Jenkins to manage mainframe components in PDS format?

Assume somebody familiar with DevOps and mainframes, but new to Jenkins, wants to get started with Jenkins, e.g. to: investigate the feasibility of managing data stored in personal files (PDSes, i.e. ...
Pierre.Vriens's user avatar
  • 7,195
12 votes
4 answers
15k views

Jenkins installed on aws unable to launch on browser

I have a fresh aws instance with Ubuntu 14 installed. I am trying to install and run jenkins on it. I did the following steps. Installed java8 wget -q -O - https://pkg.jenkins.io/debian/jenkins-...
user avatar
12 votes
1 answer
2k views

Pass string to Jenkins job from Slack

In an ideal world our less tech-knowledgeable employees could just use a Slack command to run a job and get the results slacked back to them, negating the use of the Jenkins GUI. I found Start a build ...
Alex's user avatar
  • 4,512
11 votes
2 answers
4k views

Is it ok to have a Jenkins Server without slave node?

In my team we have one Jenkins server with one master node & one slave node in the same server. We use Jenkins Pipelines and surround everything with node{}. In a colleague's team I have seen ...
Oscar Foley's user avatar
11 votes
3 answers
2k views

What are the main differences between Jenkins and TeamCity if one is used to working with Jenkins?

These tools seem to share very similar characteristics. How complicated would it be to start using TeamCity after getting used to working on Jenkins? Are there specific concepts one needs to be ...
Ricardo Herrera's user avatar
11 votes
4 answers
3k views

How to structure DevOps related code and configs in a code repository?

We've been growing as a company, our products are expanding and our DevOps related activities and efforts are growing as well - we've switched from Bamboo to a more flexible and configurable Jenkins, ...
alecxe's user avatar
  • 849
11 votes
2 answers
8k views

What are the correct permission settings when running Docker in a Jenkins Pipeline?

I'm trying to get a new jenkins pipeline together to test new pull requests to our code. I'm using docker with the ubuntu:14.04 image to simulate our production environment. Here is a minimum working ...
tobassist's user avatar
  • 221
11 votes
2 answers
6k views

Git & Jenkins: get latest green commit on branch

We're just starting to push for CI-CD and as a baby step we're going to try updating a stack with the latest green develop once every couple of hours. I am fairly new to Git/Bitbucket, and can't ...
Alex's user avatar
  • 4,512
11 votes
1 answer
3k views

Is there a way to disable a Jenkins plugin for a single job?

I use the Build timeout plugin to alert when jobs are stuck. I have one job that triggers this alert because it contains a step with a long execution time. I would like to disable the build timeout ...
dededecline's user avatar
11 votes
1 answer
4k views

How to include a custom Slack message only on completion?

We're running Jenkins with the Slack Notification Plugin. Is there a way to send the custom message only on completion, not on start? To be clear, I don't want to disable the build started message, I'...
Alex's user avatar
  • 4,512
11 votes
1 answer
7k views

Jenkins Pipeline job; proper quoting for slackSend step

This is probably 100% user error, but I can't get a pipeline job to use a variable as the channel name in a slackSend step. This uses both the Slack plugin and the Build User Vars Plugin. I'm trying ...
Alex's user avatar
  • 4,512
11 votes
1 answer
406 views

How to upgrade job-dsl files to Jenkins 2 pipelines?

Is there a common practice for migrating a large repository of Jenkins job-dsl to Jenkins2 pipelines? I am looking for ways to test the behaviour of builds, that go a little further than comparison of ...
ᴳᵁᴵᴰᴼ's user avatar
11 votes
1 answer
802 views

Is Elastic Beanstalk suitable for enterprise-grade CD?

I'm working with a project that's using Jenkins to build and deploy microservices to Elastic Beanstalk. We deploy an integration branch to a test environment, release branches to a staging environment,...
Adrian's user avatar
  • 783
11 votes
2 answers
7k views

Is it possible to pass environment variables to multibranch pipeline job in a time of generating it via DSL?

I want to pass some environment variables in the time of generating the multibranch pipelines, so upon the build start, it will already have these variables. The only thing I found was this envInject ...
mate200's user avatar
  • 111
10 votes
2 answers
405 views

Key attributes of Continuous Integration (CI) software

I work in the IT department of automation/dev company and we are just about to implement/add CI into our set of tools. And we are having difficulties to choose the one. At the moment we've been ...
Tatranskymedved's user avatar
10 votes
3 answers
16k views

Bitbucket Pull Request Builder Configuration Jenkins

I need to integrate BitBucket with Jenkins, so that whenever a PR is opened in BitBucket, it will trigger a build in Jenkins. Can someone help describe the exact configuration step that I should ...
kumar's user avatar
  • 109
10 votes
1 answer
8k views

How do I trigger scripts on a merge or when a branch is deleted?

I am using jenkins multibranch pipelines. If a branch is merged and deleted jenkins removes the branch from the pipeline as well. This is great, but I want to run a command/script when a branch is ...
red888's user avatar
  • 253
9 votes
2 answers
2k views

How to publish Jenkins job icons externally?

I'm using Promoted Builds Plugin to assign certain icons to Jenkins jobs on certain conditions and I'd like to publish these promotion icons. How can I generate external links to these icons per each ...
kenorb's user avatar
  • 7,821
9 votes
4 answers
15k views

Trigger Jenkins job from Gitlab CI with parameters

There is supposed to be a way to trigger a Jenkins job via GitlabCi, using the respective plugin. My question is whether there is a way: a) to trigger a parameterized Jenkins job b) to pass ...
pkaramol's user avatar
  • 977

1
2 3 4 5
14