Maven - Maven is good at building Java projects in a cross-platform way. It manages dependencies, and actually the whole life cycle of a project. This is an ansible-role to install Maven.
This role was built for Ubuntu Trusty or RedHat systems like RHEL/Centos 7. It needs dockpack.base_java8.
You can set the maven_version:, now 3.6.3
There are 3 variables that you would store in a vault file:
mvn_master_password:
mvn_repo_username:
mvn_repo_password:
Maven needs Java8. This role depends on dockpack.base_java8, which will be installed automatically if you use this one.
Manual use of Maven
mvn -X deploy:deploy-file -DgroupId=$GROUPID -DartifactId=$FILENAME -Dversion=$VERSION -DgeneratePom=true -Dpackaging=jar -DrepositoryId="0ss-releases" -Durl="https://repo.example.com/path/releases" -Dfile=redis.jar
For a complete example with this role check out my buildserver: git clone https://github.com/bbaassssiiee/buildserver.git
Example of how to use this role:
- hosts: servers
roles:
- { role: dockpack.base_java8 }
- { role: dockpack.base_maven }
MIT
Bas Meijer @bbaassssiiee