Install Maven with Yum on Amazon Linux
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
|sudo wget http://repos.fedorapeople.org/repos/dchen/apache-maven/epel-apache-maven.repo -O /etc/yum.repos.d/epel-apache-maven.repo|
|sudo sed -i s/\$releasever/6/g /etc/yum.repos.d/epel-apache-maven.repo|
|sudo yum install -y apache-maven|
Jun 24, 2019
Thanks a lot.....
Jun 27, 2019
Appreciate you for sharing this. It worked like a charm :)
Jun 28, 2019
Sep 27, 2019
still is not working. i tried to check my PATH, echo $M2_HOME (it's invisible, not showing) does anybody have a suggestion?
Oct 1, 2019
Thanks, @sebsto. This works on Amazon Linux 2.
Dec 6, 2019
perfect thank you so much
Dec 19, 2019
thanks a lot
Apr 22, 2020
This worked great but set maven (and my default java) to use Java 1.7. If you want to use Java 1.8, follow the above gist and then do:
yum search java | grep openjdk yum install java-1.8.<revision number from yum search>-openjdk-headless.x86_64 yum install java-1.8.<revision number from yum search>-openjdk-devel.x86_64 update-alternatives --config java #pick java 1.8 update-alternatives --config javac #pick java 1.8
Thank you so much!
Aug 27, 2020
Sep 22, 2020
You saved me a ton of time, thanks!
Dec 28, 2020
Feb 19, 2021
Jul 9, 2021
Thanks!!!!!!! Works great.
Oct 28, 2021
This worked, thanks so much, you are legend!
Nov 7, 2022
how we can update maven version on amazon ec2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment