'sudoers.cyberark' PATH environment variable overwrite workaround for macOS/Linux

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Endpoint Privilege Manager (EPM) Articles
1 min read
L1 Bithead
No ratings
For those macOS users who were previously using 'sudoers' file to source their PATH environment variable, there is a clever workaround for making additions to PATH without the need to edit /etc/sudoers.cyberark file that is used by EPM and should not be modified.

Steps

# Open text editor (vim/nano):

vim ~/.zshrc

# Scroll to the bottom of the file (SHFT+G in vim)

# Type ‘i’ to insert

PATH="$PATH:/path/to/env/var"

# For instance:

PATH="$PATH:/usr/bin/bash"

# Save the file:

:wq

# Source the file running the following command:
 
source ~/.zshrc

# Confirm the change updates PATH by running the following command:

echo $PATH
Rate this article: