Created
December 13, 2025 12:50
-
-
Save gchait/eb1d6ab534aefab06014d31135e23c85 to your computer and use it in GitHub Desktop.
Run many functions as root with injected environment variables
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| provision() { | |
| xx() { | |
| : | |
| } | |
| yy() { | |
| : | |
| } | |
| zz() { | |
| : | |
| } | |
| xx | |
| yy | |
| zz | |
| } | |
| sudo -E bash -euc "$(declare -f provision); provision" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment