Monthly Archives: August 2017

System Level Environment Variables in RHEL 7

System Level Environment Variables in RHEL 7

Environment variables are created using export statement. In order to create a system wide environment variable, the export must be executed when any user is logged-in.

You can copy scripts that need to be executed when a user is logged-in in /etc/profile.d directory. Just create a file with extension .sh (e.g. envVars.sh) and copy the following:

vi /etc/profile.d/envVars.sh

And update the contents with the following:

export PATH=$PATH:/opt/jdk/1.8.0_101l64/bin
export JAVA_HOME=/opt/jdk/1.8.0_101l64

Now try creating another bash session on the server using Putty and run java

Run Java

Run Java

Setting up IntelliJ IDEA behind Proxy

Plugins Download

First you need to set proxy for plugins download. Go to File\Settings and open Plugin tab. Get Proxy settings from internet explorer (Internet options) and update it here:

Settings

org.scala-sbt#sbt;0.13.16: not found

Here you need to use the same version build.propeties file as the one in sbt launcher.
Check SBT Version on your machine by using sbt sbt-version command and update the same version in your project\build.properties file.

Setup SBT Proxy in IntelliJ:

Please update the proxy setting as specified in the post here:

sbt_option

SBT Behind Proxy

SBT Behind Proxy

If you are running sbt behind firewall, you need to update proxy settings to be used:

sbtconfig.txt

Update the sbtconfig.txt where you have sbt installed:

In addition to this, please make sure that sbt is added to $PATH variable.

Using SBT from Git Bash

Even though I had it configured as follows, I kept getting the following message in my Git Bash:

You probably access the destination server through a proxy server that is not well configured. You probably access the destination server through a proxy server that is not well configured. You probably access the destination server through a proxy server that is not well configured.

In order to get rid of this message and use sbt I had to create a new file .bashrc and add the following proxy details to it: