Appvance IQ Jenkins plugin configuration example
About Jenkins plugin configuration example
-
Information within illustrates how to configure and run scenarios from Jenkins
- Applicable for both Jenkins installed locally as well as in the cloud, such as using Cloudbees-Jenkins
Local Jenkins Install Prerequisites
- Install Jenkins using https://jenkins.io
- After install, Jenkins automatically launches using port 8080. To change the port number, locate Jenkins/jenkins.xml and modify the --httpPort argument
For example: -Xrs -Xmx256m -Dhudson.lifecycle=hudson.lifecycle.WindowsServiceLifecycle -jar "%BASE%\jenkins.war" --httpPort=8081 -
Restart Jenkins
From a Windows Server machine, go to Server Configuration and select Restart Jenkins Service - Install ANT using http://ant.apache.org/bindownload.cgi
- Open Jenkins
- Click Manage Jenkins
- Click Configure System
- Scroll to Global Properties
- Check Environment variables
- Enter PATH in the Name box
- Enter the Java and Antpaths in the Value box as illustrated below
- Click Save (Changes)
Configure Project to Point to Plugin
- Create a new, or open and existing, Jenkins project
- Locate Source Code Management
- Options based on Jenkins Plugin location
- If hosted by Appvance, select Git and enter https://gitlab.com/Appvance-Public/Jenkins-Plugin.git in the Repository URL box
NOTE: Please make sure to install git on the machine where Jenkins is installed, once installed please restart Jenkins service.
Download git from https://git-scm.com/downloads based on your operation system.
- If self-hosted
- Select your source code management provider and enter the URL to your hosted plugin in the Repository URL box
- If hosted by Appvance, select Git and enter https://gitlab.com/Appvance-Public/Jenkins-Plugin.git in the Repository URL box
Configure Scenario to Run
- Locate Invoke Ant in the Build options
- Enter run in the Targets box
- Click Advanced
- Enter CloudBees/build.xml in the Build File box (may vary if plugin self-hosted)
- Enter the following in the Properties box:
ServerURL=<urlToAppvanceUTPServerIncludingPort>
Path=REPOSITORY/<pathToScenarioFileIncludingScenarioNameAndFileExtension>
Username=<appvanceUserName>
Password=<appvancePassword>
Notice the Path value contains REPOSITORY. Using the cloud version of Jenkins, users should specify scenarios available from a repository (i.e. SVN or GIT)
To run scenarios using local files, Jenkins must be installed on a local machine, after which local paths can be specified in place of REPOSITORY paths using SERVER. - Click Save
Running a Scenario
Appvance IQ logging, and a URL to further results, appear in Console Output as part of the project build logs.