/ Published in: Java
Setup artifactory application in a internal network that act as proxy. Then in your $HOME/.m2 directory, add the following file.
For deploying to repos, add this to pom.xml
...
cnx.release.repo
Connextions Repository for Maven2
http://firebird:8081/artifactory/cnx-releases
cnx.snapshots.repo
Connextions Repository for Maven2
http://firebird:8081/artifactory/cnx-snapshots
...
run: maven deploy -DrepositoryId=cnx.snapshots.repo
For deploying to repos, add this to pom.xml
...
cnx.release.repo
Connextions Repository for Maven2
http://firebird:8081/artifactory/cnx-releases
cnx.snapshots.repo
Connextions Repository for Maven2
http://firebird:8081/artifactory/cnx-snapshots
...
run: maven deploy -DrepositoryId=cnx.snapshots.repo
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
<?xml version="1.0"?> <settings xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd"> <mirrors> <mirror> <id>my.repo</id> <mirrorOf>*</mirrorOf> <url>http://firebird:8081/artifactory/repo</url> <name>Artifactory</name> </mirror> </mirrors> <servers> <server> <id>my.release.repo</id> <username>deployer</username> <password>deployer123</password> </server> <server> <id>my.snapshots.repo</id> <username>deployer</username> <password>deployer123</password> </server> </servers> </settings>