I have a jenkins continuous integration service running that manages the automated deployment of our software to a development machine.
So far, I have successfully set up the server to copy over the necessary files and have an upstart script that will manage and run the server process.
However, in order to restart a service I have to "sudo service service-name restart" which requires that I pass the password in the shell command.
I would like to avoid have the password plain text even if it is the development machine and the connection is ssh. The password still shows up in the console logs in jenkins and that is a no go for me.
How can I get the ssh connection to the machine to restart the service without having the password plain text?