I need a way to have Jenkins perform an action on receiving an email. I plan on sending an email with a Ruby script and net/smtp.
2 に答える
I'm also not aware of a plugin for Jenkins to start jobs via email. However, it is easy to use a service like CloudMailin (which converts the incoming email to an HTTP POST) and use a small script of your own to make this interact with the Jenkins API and schedule jobs.
I've done this personally and it works pretty well. I didn't make full use of the API and just used the following URL:
http://SERVER_URL/job/JOB_NAME/build?delay=60
You don't need the delay but I found it useful to ask multiple jobs to be set at the same time.
Jenkins にメールでコマンドを送信できるプラグインがあります。個人的には使用していませんが、ここにあります:
https://wiki.jenkins-ci.org/display/JENKINS/Mail+Commander+Plugin