SUNScholar/Prepare Ubuntu/S04

From Libopedia
Revision as of 14:08, 30 October 2019 by Ivdl (talk | contribs) (→‎Step 4. Install the Maven Java WAR builder)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Step 4. Install the Maven Java WAR builder


  1. Check this first:
  2. See below the output of the maven version on Ubuntu 16.04 LTS:
Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-10T18:41:47+02:00)
Maven home: /usr/share/maven3
Java version: 1.8.0_222, vendor: Private Build
Java home: /usr/lib/jvm/java-8-openjdk-amd64/jre
Default locale: en_ZA, platform encoding: UTF-8
OS name: "linux", version: "4.4.0-159-generic", arch: "amd64", family: "unix"

Step 4.1: Install Maven

Type as follows:

sudo apt-get install maven

Step 4.2: Create the Maven home folder

(Optional: This may or may not be needed) Type the following;

mkdir $HOME/.m2

Step 4.3: Setup the Maven config file

You can skip this step if you have a direct connection to the internet. The Maven configuration file is only needed if your connection to the internet is via a campus proxy server.

Maven proxy notes

Use the proxy settings for your campus. Check with your IT department. You need to ensure that the following two sites are allowed to pass through your campus proxy server and/or campus firewall:


More information about Maven can be found here at the following links:

Maven proxy config file

Type the following to enable Maven proxy settings:

nano $HOME/.m2/settings.xml

Tip: It is always a good idea to maximise the open nano window so that the copy and paste of long lines does not wrap around.

Add the following:

<settings xmlns=""
Replace everything between the % signs with your campus settings !