Change settings.xml location
Case
You have to use a custom-set settings.xml file, rather the default one.
By default, settings.xml is assumed to be in one the two following folders:
$M2_HOME/conf/settings.xml
$HOME/.m2/settings.xml
Fix
Use the -s
option, for instance:
mvn install -s /path/to/file/otherSettings.xml