Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

4
  • 3
    Does your sudoers policy preserve arbitrary environment variables? what happens if you change the command to sudo -E timeout 15 2.sh? Commented Apr 22, 2019 at 0:28
  • @steeldriver Yea that seems to have been the oversight. It works as I hoped now thanks! Commented Apr 22, 2019 at 0:43
  • @steeldriver, that comment sounds like The Answer; will you post it? Thank you! Commented Apr 22, 2019 at 1:00
  • @JeffSchaller I've added a brief answer below - TBH I'm not entirely familiar with the details Commented Apr 22, 2019 at 1:25