Dashboards & Visualizations

Splunk Jenkins app dashboard not fetching console logs of pipeline jobs

rakesh635
Engager

Have configured splunk plugin in jenkins and have installed jenkins app for splunk. Everything seems to be working, except, jenkins_console index is not receiving console logs of pipeline jobs.
Can anyone guide me how to make this work.

Tags (1)
0 Karma
1 Solution

rakesh635
Engager

I figured out and it can be done, doing some modifications in pipeline script,

scripted pipeline

sendSplunkConsoleLog {
node{
sh "echo testjob";
}
}

declarative pipeline

pipeline {
agent any
options {
timeout(time: 1, unit: 'HOURS')
sendSplunkConsoleLog()
}
stages {
stage('Example') {
steps {
echo 'Hello World'
}
}
}
}

View solution in original post

0 Karma

rakesh635
Engager

I figured out and it can be done, doing some modifications in pipeline script,

scripted pipeline

sendSplunkConsoleLog {
node{
sh "echo testjob";
}
}

declarative pipeline

pipeline {
agent any
options {
timeout(time: 1, unit: 'HOURS')
sendSplunkConsoleLog()
}
stages {
stage('Example') {
steps {
echo 'Hello World'
}
}
}
}

0 Karma
Get Updates on the Splunk Community!

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer at Splunk .conf24 ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...

Share Your Ideas & Meet the Lantern team at .Conf! Plus All of This Month’s New ...

Splunk Lantern is Splunk’s customer success center that provides advice from Splunk experts on valuable data ...

Combine Multiline Logs into a Single Event with SOCK: a Step-by-Step Guide for ...

Combine multiline logs into a single event with SOCK - a step-by-step guide for newbies Olga Malita The ...