Category: Continuous Integration

Using Docker to run Jenkins jobs

Here is a small recipe you can use to run Jenkins jobs in Docker containers. Docker is a solution to easily automate the deployment and execution of applications inside software containers on top of Linux. The main advantages to use containers are the isolation of resources, restriction of services, and processes provisioned to have a …

Continue reading

How to trigger a build remotely?

Jenkins gives a nice way to trigger builds remotely through its ReST API. The first problem that comes is to find a way to use this API without using your own account. Indeed, it is a bad idea to share your credentials with anyone having access to this script. To solve this issue, you can …

Continue reading

How to trigger a build from an upstream project hosted on a remote Jenkins?

Sometimes, you need to trigger a build of your job from a job hosted on a remote Jenkins. In this case, you cannot use the “build after other projects” trigger. The best option is to install the URL trigger plugin. Then in your job configuration, add an URL trigger on the following URL: https://a-jenkins-server.org/job/job-name/lastSuccessfulBuild/buildNumber. Of course, …

Continue reading