Platinum Partner
architects,devops,tips and tricks,tools & methods

Jenkins? Tomcat? Running Code w/ Permissions?

This script will probably help you! If you need to run some "SUDO" commands from Jenkins, you will probably need to first: 

1) Add jenkins user to SUDO, and 
2) Avoid passwords.

The following code will do it like a miracle:

echo 'jenkins  ALL= NOPASSWD: ALL' >> /etc/sudoers
echo 'Defaults:jenkins    !requiretty' >> /etc/sudoers

Published at DZone with permission of {{ articles[0].authors[0].realName }}, DZone MVB. (source)

Opinions expressed by DZone contributors are their own.

{{ tag }}, {{tag}},

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}
{{ parent.authors[0].realName || parent.author}}

{{ parent.authors[0].tagline || parent.tagline }}

{{ parent.views }} ViewsClicks
Tweet

{{parent.nComments}}