Reputation: 47
I would like to use Solar Putty's ability to run post authentication scripts. currently, I created a simple sudo script that it calls "sudo -iu flanger" which is stored in an external .sh file.
I imported the script and attached to my session so that on load it will call it. I noticed that I had to include one line break above the sudo command inorder for it to run ...and it works.
Now, I want to create a different script that would call the same sudo but aftwards would execute a script I have on the server. I tried the same thing in my local script by including a new line break and with the call to execute the script but it acts like it is ignoring it.
Is this even possible what I am attempting:
Upvotes: 1
Views: 421
Reputation: 1
For me on Ubuntu sudo -iu
doesn't work, but sudo -i
does. To keep it open I have to add bash to the end of the script and you'll get a shell open to the password prompt.
Upvotes: 0