I need help about sending file (log file) from Jenkins to Discord using Pipeline. I have seen there is an option on post-build action using Freestyle project, but for this project I need to use Pipeline.
Thank you in advance
I have read this site https://plugins.jenkins.io/discord-notifier/ but still got no clue how to send log file to Discord.
Related
From time to time my pipeline fails due to an HTTP request error 401, while trying to get the jenkins file from BitBucket. In this case, instead of crashing with an error message, I'd like to print a friendly error message and possibly send an email.
Is there a way to check for connectivity to the BitBucket server, before trying to run the pipeline? If this is not possible, can I catch this error somehow, and take action on it?
I'm guessing this would have to be something built into Jenkins, or on the Jenkins server, since my jenkins file resides within the repository on the BitBucket server.
An thoughts would be greatly appreciated, as I'm a Jenkins novice.
Trying to create the webhook in Bit-bucket for the multi-branch pipeline. I wanted to trigger the build whenever changes are pushed to bit-bucket. It's working for a simple and pipeline project, build is automatically triggered whenever a change is pushed. But it's not working for the multi-branch pipeline. I can see the request in the ngrok console and on the bitbucket webhook console with status 200.
This is my webhook URL http://*****.ngrok.io/bitbucket-hook/.
FYI: I m using ngrok tool to publish my local Jenkins to be accessible publicly.
Any help will be greatly appreciated! Thanks.
This worked for me giving the URL as https://<Jenkins url>/bitbucket-scmsource-hook/notify?server_url=https://<bitbucketUrl>
In Bit-bucket you just replace this one -- http://*****.ngrok.io/bitbucket-scmsource-hook/notify
I want to have the option to send the whole jenkins build log to a slack channel. I currently output the status of the builds successfully to slack, I would like to send the build log if the build fails. Does anyone know how to do this?
I have tried creating a shell script to zip up the log on the jenkins server and then posting it.
You can use Incoming WebHooks or Slash Commands both are the same.
I'm also using both for sending my Jenkins to build artifact to slack channel but.
You can add an attachment also in this hooks or Jenkins generate URL for all build artifacts and you can just pass that URL on slack and user can download it via slack.
you have to user slack plugin on Jenkins and configure your slack token and stuff like that.
If you need more detail contact me.
I would like to send my results from Jenkins to another website. The files are available in zip. Is there anybody who can give advice, what can i use to realize this ? I wrote my pipeline in groovy
Thank you
You can use curl in the jenkins job to upload the files.
I would like to ask is there any way to query run time build steps by using Jenkins pipeline REST API? I refer to this link https://github.com/jenkinsci/pipeline-stage-view-plugin/tree/master/rest-api and it seems like I can't get a run time build steps command line that I configure for Jenkins pipeline job.
Any suggestions?
It seems there is no possibility to get this information via the REST API. I found a solution somewhere.
With
http://Serverurl/job/jobname/config.xml
you can download the config file and parse the XML. Doing it with PowerShell and it's working fine.