Skip to main content

Easy guide to install Maven in Ubuntu 16.04


Before installation I am recommending to make the system into a latest stable versions
1. sudo apt-get update -y
2. sudo apt-get upgrade -y

Install Java:

1. sudo add-apt-repository ppa:webupd8team/java
2. sudo apt update; sudo apt install oracle-java8-installer
//run command to run the system package & install Java installer script
//can replace (oracle-java9-installer)
3.Accept the terms of license and agreements in order to continue the download
4. javac -version
    java -version
//to check the java version
5.sudo apt install oracle-java8-set-default
//java versions can be differ so setting the default Java Environment

Installing Maven :

Step 01
1. sudo apt-get install Maven
2.mva -v
//to check whether the Maven is installed.

Step 02: Download and install Maven
1. wget [website link you want to download]
Example – wget http://www-eu.apache.org/dist/Maven/Maven-3/3.5.0/binaries/apache-Maven-3.5.0-bin.tar.gz
Go to ApacheMaven download side and choose what do you want to download. If it is a command line argument through terminal you have to “copy link address” and past that after “wget” command as shown in the above example.
//if the permission denied to download the file. Try that by using “sudo” before “wget” to ensure that you are the administrator
2. sudo tar -xf apache-Maven-3.5.0-bin.tar.gz -c /usr/local
//unzipping the downloaded file in the location of /usr/local
3. cd /usr/local
//move to the extracted file location
4. sudo ln -s apache-Maven-3.5.0 Maven
//creating the link to the Maven
5. sudo vi /etc/profile.d/Maven.sh
//create Maven_HOME (by creating “Maven.sh” file
6. export M2_HOME=/usr/local/Maven
    export PATH=${M2_HOME}/bin:${PATH}
//type the above given lines inside the “Maven.sh” through the vi editor. Don’t forget to save the file.
7. source /etc/profile
//activate the Maven environmental variable
8. mvn -v
//to check the whether Maven installed correctly 

©IT Today

Comments

Popular posts from this blog

What is Google Hacking?

As an ethical hacker we have need to follow some general steps to be a good ethical hacker. Such that steps/stages can be listed as follows. But these steps are not a defined one. We can change them according to our needs. 1    . Reconnaissance – Gathering the information which are having the security vulnerability. 2   . Scanning - Examine/explore a target machine/network for the vulnerability that can be make use to go inside. 3    .Gaining Access – After scanning process make use of the vulnerability and attempt to move inside to the system to exploit. 4    . Maintaining Access – After moved into the machine/network hacker needs to make some backdoor to gain the access again. 5    . Clearing Tracks (unethical) – Clearing the traces of all the activities what they done in their hacking process. 6    . Reporting – End of the ethical hacking process in order to make some notes on the findings, things done in the hacking...

1st Program in Maven @ Ubuntu

Maven What is Maven? It is a Build tool – building a code in a development environment Project management tool – it helps to generate reports, helps in the dependency management, etc. Maven as a Build tool. Why we are using Maven? To reduce the common problems and activities which are needed, when we are developing applications. 1. Multiple jars – Program may contain one/many frameworks and frameworks are need to include it all the required “jar”. “jar” are need to available in compile time, need to bundle them in the distribution. (We can miss something/ we don’t know what is jar?) 2. Dependencies and versions – a jar can depend on another jar, so we have need to make sure that all my dependencies are closed and make sure that I have supplied all the dependencies. Dependencies could differ bases on the versions. 3. Project structure – Proper structure for the application. (E.g. Directories, libraries , etc.) 4. Building, publis...

'OpenID Connect' Client App Creation on Auth0

If we are going to use OIDC (OpenID Connect), we have need to know the definitions of OAuth and OIDC. Because OAuth is for authorization and OIDC is on top of OAuth to provide authentication. So, OIDC is providing authorization and authentication.   What is OAuth? The OAuth 2.0 authorization framework enables third-party applications to obtain limited access to a web service. [To see more on OAuth itwithcs.blogspot.com: Click here ] What is OpenID Connect? OpenID Connect is a simple identity layer on top of the OAuth 2.0 protocol. It allows Clients to verify the identity of the End-User based on the authentication performed by an Authorization Server, as well as to obtain basic profile information about the End-User in an interoperable and REST-like manner. It uses simple JSON Web Tokens (JWT), which you can obtain using flows conforming to the OAuth 2.0 specifications. What are Identity Servers? Identity server are the core part of any identity and access control i...