embedded/bin should never be in the user's $PATH
Nobody has claimed this yet.
- Dominant language
- Ruby
- Stars
- 18
- Forks
- 23
- Avg merge
- 5d 17h
- Merged PRs (30d)
- 1
Description
The /opt/chefdk/embedded/bin/ directory should never be in a user's $PATH. It contains executables that can interfere with with the normal working of a users system, such as clear, tput, xz, xml2-config, xslt-config, etc.
According to @lamont-granquist it was never intended to ever be put in the user's $PATH: chef/omnibus-chef#340
However, chef shell-init does add embedded/bin to the path:
$ chef shell-init bash
export PATH="/opt/chefdk/bin:/Users/docwhat/.chefdk/gem/ruby/2.1.0/bin:/opt/chefdk/embedded/bin:/opt/chefdk/bin:..."
export GEM_ROOT="/opt/chefdk/embedded/lib/ruby/gems/2.1.0"
export GEM_HOME="/Users/docwhat/.chefdk/gem/ruby/2.1.0"
export GEM_PATH="/Users/docwhat/.chefdk/gem/ruby/2.1.0:/opt/chefdk/embedded/lib/ruby/gems/2.1.0"
Further, ChefDK is crippled if you don't add embedded/bin to the $PATH
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the chef shell-init entry point and reproduce the Bash output shown in the issue. Trace why /opt/chefdk/embedded/bin is added to PATH, then verify that the generated environment no longer exposes it while ChefDK remains functional without that directory in PATH.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- bash, ruby
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100