2015-03-17 4 views
0

Как настроить Maven (settings.xml) и Artifactory для доступа ко всем репозиториям через Artifactory? Мои текущие настройки следующие, и я даже не могу запустить плагин Maven-deploy . Ошибка в том, что он не был найден в любых сделок РЕПО (местный + Artifactory)Как настроить maven?

<?xml version="1.0" encoding="UTF-8"?> 
<settings xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.1.0 http://maven.apache.org/xsd/settings-1.1.0.xsd" xmlns="http://maven.apache.org/SETTINGS/1.1.0" 
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> 
    <servers> 
    <server> 
     <username>xxx</username> 
     <password>xxx</password> 
     <id>central</id> 
    </server> 
    <server> 
     <username>xxx</username> 
     <password>xxx</password> 
     <id>snapshots</id> 
    </server> 
    </servers> 
    <mirrors> 
    <mirror> 
     <mirrorOf>*</mirrorOf> 
     <name>repo</name> 
     <url>http://[host]:[port]/artifactory/repo</url> 
     <id>repo</id> 
    </mirror> 
    </mirrors> 
    <profiles> 
    <profile> 
     <repositories> 
     <repository> 
      <snapshots> 
      <enabled>false</enabled> 
      </snapshots> 
      <id>central</id> 
      <name>libs-release</name> 
      <url>http://[host]:[port]/artifactory/libs-release</url> 
     </repository> 
     <repository> 
      <snapshots /> 
      <id>snapshots</id> 
      <name>libs-snapshot</name> 
      <url>http://[host]:[port]/artifactory/libs-snapshot</url> 
     </repository> 
     </repositories> 
     <pluginRepositories> 
     <pluginRepository> 
      <snapshots> 
      <enabled>false</enabled> 
      </snapshots> 
      <id>central</id> 
      <name>plugins-release</name> 
      <url>http://[host]:[port]/artifactory/plugins-release</url> 
     </pluginRepository> 
     <pluginRepository> 
      <snapshots /> 
      <id>snapshots</id> 
      <name>plugins-snapshot</name> 
      <url>http://[host]:[port]/artifactory/plugins-snapshot</url> 
     </pluginRepository> 
     </pluginRepositories> 
     <id>artifactory</id> 
    </profile> 
    </profiles> 
    <activeProfiles> 
    <activeProfile>artifactory</activeProfile> 
    </activeProfiles> 
</settings> 

[хост]: [порт] реальны в файле и так [имя пользователя] [пароль] проверяется, что в 3 раза.

[ERROR] No plugin found for prefix 'deploy' in the current project and in the plugin groups [org.apache.maven.plugins, org.codehaus.mojo] available from the repositories [local (C:\Users\[username]\.m2), repo (http://[host]:[port]/artifactory/repo)] -> [Help 1]  
+0

'http: // host/port /' не похоже на правильное имя хоста и порт –

+0

это правильный хост и порт в файле, извините за неоднозначность @Lashane –

ответ

0

Artifactory может сгенерировать правильный файл settings.xml для вас. Найдите ссылку Maven Settings в правом меню на главном экране.

Смежные вопросы