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

Docker plugin does not work when executed within STS #17

Open
robert-bor opened this issue Feb 16, 2017 · 1 comment
Open

Docker plugin does not work when executed within STS #17

robert-bor opened this issue Feb 16, 2017 · 1 comment

Comments

@robert-bor
Copy link
Contributor

You will see the following error:

Cannot run program "docker": error=2, No such file or directory

STS cannot find Docker because it was not started up with the environment's env variables. See Transmode/gradle-docker#65

The following solution has been witnessed to work:

open -a "STS" &

This will startup STS with all the environment variables.

Thanks to Bas for pointing out the error.

@sptdevos
Copy link
Member

sptdevos commented Feb 16, 2017

The problem is that my IDE does not have the same PATH available as my terminal.
To be able to start my IDE from the dock and still be able to run docker from it I had to fix the PATH for this application:

In /Applications/STS.app/Contents/Info.plist I had to add a <key>/<dict> pair to the existing <dict> node:

<key>LSEnvironment</key>
<dict>
    <key>PATH</key>
    <string>enter the output of "echo $PATH" here...</string>
</dict>

Do not forget to run following command to apply changes to Info.plist:
/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -v -f /Applications/STS.app

No need to run 'open -a "STS" &' from terminal anymore!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants