mirror of
https://github.com/gravitational/teleport.git
synced 2026-11-04 02:21:02 +08:00
* Script oneoff: add optional command prefix (sudo) We are converting the installer script used for Server Auto Discover to use go instead of shell script. As an example, in EC2 Auto Discover, the script runs as `ssm-user` which has access to using `sudo`. This script is currently using `sudo` to change system wide configurations (adding repos, installing packages, create file locks, ....). In order to convert this script into go code, we must also run with elevated privileges. This PR changes the `oneoff` script to optionally run with a prefix. Only `sudo` can be used as a command prefix. * use t.cleanup and fix sudo usage when testing