Environment variables for the Eclipse plugin
To analyze open-source dependencies and IAC template files, the plugin uses the Snyk CLI. The CLI needs the following environment variables:
- PATH: The path to needed binaries, for example, to Maven. You can also adjust the- PATHvariable manually using the- Pathfield in the settings dialog.
- JAVA_HOME: The path to the JDK you want to use to analyze Java dependencies.
- http_proxyand- https_proxy: Proxy set using the value in the format- http://username:password@proxyhost:proxyport. Note that the leading- http://in the value does not change to- https://for an- https_proxy. If you populate the proxy settings in Eclipse, the Snyk plugin will set the environment variables automatically for Language Server and CLI.
Setting these variables only in a shell environment (for example, using ~/.bashrc) is not enough, if you do not start Eclipse from the command line or create a script file that starts Eclipse using a shell environment.
- On Windows, set the variables using the GUI or on the command line using the setx tool. 
- On macOS, the process - launchdneeds to know the environment variables to launch Eclipse directly from the Finder. Set these environment variables using the- launchctl setenvcommand, for example, on startup or using a script you launch at user login. Note that providing environment variables to the macOS UI may change between operating system releases, so it can be easier to create a small shell script that launches the Eclipse app to leverage the shell environment. This can be defined using- ~/.bashrc.
- On Linux, you can update the file - /etc/environmentto propagate the environment variables to the window manager and UI.
Last updated
Was this helpful?

