Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document macOS node Jenkins agent PATH env setup to avoid SIP protection issues #2010

Open
andrew-m-leonard opened this issue Mar 9, 2021 · 3 comments

Comments

@andrew-m-leonard
Copy link
Contributor

To avoid Apple MacOS SIP protection causing bash environment permission protection, we must find bash from /usr/local/bin and not /usr/bin, /usr/local/bin does not get the SIP permission applied to it.

The Jenkins Agent environment setup for PATH must have /usr/local/bin prefixed to achieve this, eg:
image

@aahlenst
Copy link
Contributor

aahlenst commented Mar 9, 2021

Uh. Why can't we just alter the default shell?

@gdams gdams changed the title Document MacOS node Jenkins agent PATH env setup to avoid SIP protection issues Document macOS node Jenkins agent PATH env setup to avoid SIP protection issues Mar 9, 2021
@sxa
Copy link
Member

sxa commented Mar 10, 2021

Uh. Why can't we just alter the default shell?

Do you mean the default shell for the user? I wouldn't want to set the default for everyone on the system to something that was in /usr/local It may depend which shell jenkins uses when it spawns off another shell, or if it runs specifically bash thescript.sh (which would likely use whatever was in the PATH)

@aahlenst
Copy link
Contributor

aahlenst commented Mar 10, 2021

Do you mean the default shell for the user?

Yes. chsh -s /usr/local/bin/bash, but obviously via Ansible.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Todo
Development

No branches or pull requests

3 participants