Jenkins CI Deployment on MacOS

Monday 16 February 2015

Install Jenkins

Install Jenkins
It's pretty easy to install Jenkins on MacOS.
Just download this pkg and follow the install wizard.
Hit http://localhost:8080 and you will see the Jenkins Dashboard.

Jenkins Config
Config path of JDK, Git and Maven.
You can also refer this vedio.

Install github plugin
Go to pluginManager page to install github plugin. Choose Available tab and input 'github' as filter in the top-right corner. Choose Github Plugin, download and install it.

Hit localhost:8080/restart to restart Jenkins.

Config github Web Hook

Now we need to config github web hook to enable builder trigger.

Jenkins config
In Jenkins config, choose "Let Jenkins auto-manage" hook URLs and fill API URL, Username(optional) and OAuth token. GithubWebHook.png

Jenkins Project config
In your project config: http://localhost:8080/job/YOUR-PROJECT/configure check the box: BuilderTriggers

Github Config
In github config: https://github.com/YOUR-NAME/REPO/settings/hooks, set the payload URL. If you are using local machine, first, we’ll install ngrok to expose local host to the Internet.

You can expose your localhost by running ./ngrok http 8080 on the command line. You should see a line that looks something like this:

Forwarding http://128cd298.ngrok.io -> localhost:8080

BuilderTriggers

Now pushes to your Github repository will automatically trigger builds in Jenkins.

comments powered by Disqus