You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
Michael f4e0d5cc86
Update MAC_LINUX_DOCKER.md
4 years ago
.github Initial commit 4 years ago
src Add source to Hello-Maven 4 years ago
.gitignore Initial commit 4 years ago
03_01.md Update the repo URL 4 years ago
CONTRIBUTING.md Initial commit 4 years ago
LICENSE Initial commit 4 years ago
MAC_LINUX_DOCKER.md Update MAC_LINUX_DOCKER.md 4 years ago
NOTES.md Add source to Hello-Maven 4 years ago
NOTICE Initial commit 4 years ago
README.md Update README.md 4 years ago
WINDOWS.md Update WINDOWS.md 4 years ago
pom.xml Add source to Hello-Maven 4 years ago

README.md

Learning Jenkins, 03-01: Using a global build tool

Prerequisites

You will need to configure Maven as a global build tool.

In the Jenkins web interface, go to:

Manage Jenkins -> Global Tool Configuration -> Maven installations -> Add Maven.

Give your Maven installation a name and check the option to Install automatically.

Setting up the Jenkins Job

Create a freestyle job and configure it as follows:

  1. Under Source Code Management, select Git and enter the following URL:
https://github.com/LinkedInLearning/learning-jenkins-3003221
  1. MAKE SURE TO SET THE Branch Specifier to */03_01.
  2. Add a build step using Invoke Top-Level Maven Target.
  3. Select the Maven version you configured in the previous step.
  4. For the goal, enter package.

WINDOWS SYSTEMS

Select the Execute Windows batch command build step

java -cp target/hello-1.0-SNAPSHOT.jar com.learningjenkins.App

Save the job and start the build.

Follow this link for more details on Windows

MacOS, Linux, and Docker

Select the Execute shell build step.

java -cp target/hello-1.0-SNAPSHOT.jar com.learningjenkins.App

Save the job and start the build.

Follow this link for more details on MacOS, Linux, and Docker

Troubleshooting Errors

ERROR: Couldn't find any revision to build. Verify the repository and branch configuration for this job.

This error means you have probably entered the wrong branch under Source Code Management. You need to enter */03_01 for the branch.