title: Configuring Maven proxy user and password via Maven OPTS
body: <p>Currently I have setup the maven proxy(For a Spring Boot maven wrapper) up like:</p>
  
  <pre><code>MAVEN_OPTS=-Dhttp.proxyHost=proxy.company.com -Dhttps.proxyHost=proxy.company.com -Dhttp.proxyPort=8080 -Dhttps.proxyPort=8080 -Dhttp.proxyUser=myUserName -Dhttp.proxyPassword=MyEpicPassword
  </code></pre>
  
  <p>While I can see in my logs that my proxy host and port are being accepted, I am getting AuthenticationRequired failures.</p>
  
  <pre><code>[WARNING] Could not transfer metadata org.springframework.cloud:spring-cloud-build:1.2.2.BUILD-SNAPSHOT/maven-metadata.xml from/to java-releases (http://download.java.net/maven/2): Not authorized by proxy , ReasonPhrase:authenticationrequired.
  </code></pre>
  
  <p>Additional Information:  </p>
  
  <p>I am leveraging a maven wrapper project so I do not have direct access to a settings.xml file that I am aware of to opt for xml based proxy configuration.  However, if that is possible I am already familiar with how to configure my settings.xml file with a proxy.</p>
  
  <p>This question is not a duplicate because it is focused on Authentication via Maven Opts.</p>