jenkins-master-project | Jenkins Plugin : Master Project | Identity Management library
kandi X-RAY | jenkins-master-project Summary
kandi X-RAY | jenkins-master-project Summary
This is a plugin for [Jenkins] Continuous Integration Server. This plugin provides a new project type. In this new project type you can select a list of sub-projects which should be executed in one logical master project. You’re interested in contributing to this Etsy-made Jenkins plugin?.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Schedules the build
- Waits for all builds to be executed
- Gets all the parameters from master build
- Create a parameter action for the given action
- Runs the project
- Rebuilds the notification of the rebuild
- Adds a sub build
- Returns the result of the build
- Prebuild the email
- Creates an array of addresses to addresses
- Compile a Jelly template
- Send an email
- Runs the job
- Builds a new build
- Rebuild the master build
- Performs prebuild
- Returns the list of default sub projects
- Parse command line arguments
- Performs a prebuild
- Autocomplete sub projects
- Get a list of publisher descriptors
- Run the job
- Create a new build wrapper
- Checks if the given value is valid
- Configures the application
- Get the projects belonging to this project
jenkins-master-project Key Features
jenkins-master-project Examples and Code Snippets
Community Discussions
Trending Discussions on jenkins-master-project
QUESTION
Splunk Version 6.5.3.1
Splunk Build bf0ff7c2ab8b
Jenkins Version 1.642.3 or 2.32.3
On every Jenkins master, there's a splunk process running.
...ANSWER
Answered 2017-Sep-19 at 16:30Found the solutions.
I just had to use services/search/jobs/export
end point.
Let's find out what was our Jenkins host
(which contained the Jenkins job), What was the job's name (this can be parsed / grepped from the source
path for the log file) and what was Jenkins's job's actual console output (_raw
). Also, lets limit our search for finding the data within last 30 minutes (i.e. earliest=-30m
).
There are actually 3 ways to do it.
1) By passing user name and password at command line.
2) By generating a SESSION TOKEN
that we can use in any future CURL command in the headers.
3) By generating a --cookie "${COOKIE}"
ID and using that. This one is preferred method of all as it replicates cookie values to any backend servers Splunk uses. Cookie name to be used: splunkd_8081
The last 2 solutions depends upon the first method for using a user's credentials to create either the SESSION or COOKIE ID.
Solution 1:
1) Here we'll use our splunk server
2) Pass username and password in the command line
3) Provide Splunk options for finding / fetching Splunk data (for Jenkins logs containing specific lines) and also doing a little extra regex match (so that it'll return exact Jenkins build# for the source path rather than showing 3 more lines for source
for the same console output. Jenkins latestBuild, latestSuccessfulBuild etc are symlinks which point to a numbered build and we don't want to list these symlinked source
entries in our output so I'm using a regex pattern to find source
path where it contains a NUMBERED build# just before the log
file in the source path).
4) Then, I'm using |
to filter out only 3 fields: host
, source
, and _raw
(that Splunk would return). host
contains, which Jenkins server had the Jenkins job. source
contains Jenkins job name, build# etc info in it's value. _raw
variable contains the Jenkins job's console output (Few lines close to the string / line that we are trying to search for in the console output of a Jenkins job).
NOTE: All these 3 fields are available inside a dictionary variable result
so I'm just outputting that.
5) Then, I'm providing the output in json
format (you can also use csv
). Finally I'm using jq
to filter out the information.
NOTE: If you use jq -r ".result._raw"
(i.e. _raw
field inside dictionary variable result
then it'll give you LINE by LINE output for the console output (rather than giving you one blob with \n
embedded in it). You can also use sed 's/\\n/\n/g'
but jq -r ".result._raw"
was easy enough).
Commands ran:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install jenkins-master-project
You can use jenkins-master-project like any standard Java library. Please include the the jar files in your classpath. You can also use any IDE and you can run and debug the jenkins-master-project component as you would do with any other Java program. Best practice is to use a build tool that supports dependency management such as Maven or Gradle. For Maven installation, please refer maven.apache.org. For Gradle installation, please refer gradle.org .
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page