Reputation: 20222
In my Jenkins build I am using httpRequest like this:
httpRequest http://my-server.com
I would like to add username and password authentication as well, something like:
httpRequest http://my-server.com --username=myUsername --password=myPassword
I didn't find any information about this on the documentation. Any idea how this could be done?
Upvotes: 1
Views: 5219
Reputation: 369
Send the URL like this:
http://username:password@your-jenkins-server:port/
Just tested it and it worked fine.
Upvotes: 1
Reputation: 2314
Have you tried: http://myUsername:[email protected]
?
This is the usual way to send authentication data via HTTP
Upvotes: 4