<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    Terry.Li-彬

    虛其心,可解天下之問;專其心,可治天下之學;靜其心,可悟天下之理;恒其心,可成天下之業。

      BlogJava :: 首頁 :: 新隨筆 :: 聯系 :: 聚合  :: 管理 ::
      143 隨筆 :: 344 文章 :: 130 評論 :: 0 Trackbacks
    1、下載war包,部署到tomcat中,啟動tomcat;
    2、訪問:http://xxx/nexus-1.1.1/index.html;
    3、用admin/admin123登錄;
    4、修改admin的密碼,但是不要修改別的屬性和修改別的用戶信息
    5、進入administration中的repositories,依次修改三個type是proxy的項目,將其Download Remote Indexes修改為true;然后郵件他們,分別re-index一下;
    6、將你自己機器上的manven緩存(一般是在C:\Documents and Settings\登錄名\.m2下面)全部拷貝到/home/你的用戶名/sonatype-work/nexus/storage下面的central和releases各一份;
    7、修改你本地的(一般是在C:\Documents and Settings\登錄名\.m2下面)setting.xml文件改成下面的:
    Xml代碼
    1. <settings>??
    2. ??????<proxies>??
    3. ????????<proxy>??
    4. ??????????<id>normal</id>??
    5. ??????????<active>true</active>??
    6. ??????????<protocol>http</protocol>??
    7. ??????????<username>deployment</username>??
    8. ??????????<password>deploy</password>??
    9. ??????????<host>172.19.0.177:8080/nexus-1.1.1</host>??
    10. ??????????<port>80</port>??
    11. ??????????<nonProxyHosts>172.19.0.177:8080/nexus-1.1.1</nonProxyHosts>??
    12. ????????</proxy>??
    13. ??????</proxies>??
    14. ??????<servers>??
    15. ??????</servers>??
    16. ??????<mirrors>??
    17. ?????????<mirror>??
    18. ??????????<id>nexus-public-snapshots</id>??
    19. ??????????<mirrorOf>public-snapshots</mirrorOf>??
    20. ??????????<url>http://172.19.0.177:8080/nexus-1.1.1/content/groups/public-snapshots</url>??
    21. ????????</mirror>??
    22. ????????<mirror>??
    23. ??????????<!--This?sends?everything?else?to?/public?-->??
    24. ??????????<id>nexus</id>??
    25. ??????????<mirrorOf>*</mirrorOf>??
    26. ??????????<url>http://172.19.0.177:8080/nexus-1.1.1/content/groups/public</url>??
    27. ????????</mirror>??
    28. ??????</mirrors>??
    29. ??????<profiles>??
    30. ????????<profile>??
    31. ??????????<id>development</id>??
    32. ??????????<repositories>??
    33. ????????????<repository>??
    34. ??????????????<id>central</id>??
    35. ??????????????<url>http://central</url>??
    36. ??????????????<releases><enabled>true</enabled></releases>??
    37. ??????????????<snapshots><enabled>true</enabled></snapshots>??
    38. ????????????</repository>??
    39. ??????????</repositories>??
    40. ?????????<pluginRepositories>??
    41. ????????????<pluginRepository>??
    42. ??????????????<id>central</id>??
    43. ??????????????<url>http://central</url>??
    44. ??????????????<releases><enabled>true</enabled></releases>??
    45. ??????????????<snapshots><enabled>true</enabled></snapshots>??
    46. ????????????</pluginRepository>??
    47. ??????????</pluginRepositories>??
    48. ????????</profile>??
    49. ????????<profile>??
    50. ??????????<id>public-snapshots</id>??
    51. ??????????<repositories>??
    52. ????????????<repository>??
    53. ??????????????<id>public-snapshots</id>??
    54. ??????????????<url>http://public-snapshots</url>??
    55. ??????????????<releases><enabled>false</enabled></releases>??
    56. ??????????????<snapshots><enabled>true</enabled></snapshots>??
    57. ????????????</repository>??
    58. ??????????</repositories>??
    59. ?????????<pluginRepositories>??
    60. ????????????<pluginRepository>??
    61. ??????????????<id>public-snapshots</id>??
    62. ??????????????<url>http://public-snapshots</url>??
    63. ??????????????<releases><enabled>false</enabled></releases>??
    64. ??????????????<snapshots><enabled>true</enabled></snapshots>??
    65. ????????????</pluginRepository>??
    66. ??????????</pluginRepositories>??
    67. ????????</profile>??
    68. ??????</profiles>??
    69. ????????<activeProfiles>??
    70. ????????<activeProfile>development</activeProfile>??
    71. ??????</activeProfiles>??
    72. </settings>??
    ?

    ??? 將172.19.0.177地址修改為你自己的服務器地址
    ???
    8、在你的項目中的pom.xml中增加一段:

    Xml代碼
    1. <distributionManagement>??
    2. ????????<repository>??
    3. ????????????<id>repo</id>??
    4. ????????????<name>public</name>??
    5. ????????????<url>http://172.19.0.177:8080/nexus-1.1.1/content/repositories/releases</url>??
    6. ????????</repository>??
    7. ????????<snapshotRepository>??
    8. ????????????<id>Snapshots</id>??
    9. ????????????<name>Snapshots</name>??
    10. ????????????<url>http://172.19.0.177:8080/nexus-1.1.1/content/repositories/snapshots</url>??
    11. ????????</snapshotRepository>??
    12. ????</distributionManagement>??
    ?


    這樣一來經過我的測試,如果你在沒有局域網的環境中(也就是沒辦法訪問你的私服),只要將pom里面的那段刪除就可以了。

    posted on 2010-09-26 00:16 禮物 閱讀(1368) 評論(0)  編輯  收藏 所屬分類: Maven2
    主站蜘蛛池模板: jizz18免费视频| 黄色一级免费网站| 99久热只有精品视频免费看| 在线亚洲97se亚洲综合在线| 五月天婷婷免费视频| 亚洲国产成人久久笫一页| 美女啪啪网站又黄又免费| 亚洲国产av一区二区三区| 一区二区免费电影| 亚洲人成网亚洲欧洲无码久久| 免费毛片在线看不用播放器| 日韩亚洲一区二区三区| 久久精品毛片免费观看| 亚洲成av人片在线看片| 最近最新的免费中文字幕| 亚洲av日韩精品久久久久久a| 在线看片无码永久免费aⅴ| 鲁死你资源站亚洲av| 国产精品亚洲高清一区二区| 亚洲日韩在线观看| a级成人免费毛片完整版| 亚洲大片在线观看| 国产福利在线免费| 特级毛片免费播放| 婷婷精品国产亚洲AV麻豆不片| 国产曰批免费视频播放免费s| 亚洲国产成人精品无码区二本| 亚洲av无码天堂一区二区三区| 成人A片产无码免费视频在线观看| 亚洲精品影院久久久久久| 性做久久久久免费看| 日韩免费高清播放器| 亚洲情A成黄在线观看动漫软件 | 久久精品国产大片免费观看| 91亚洲精品自在在线观看| 国产一区二区三区在线观看免费| 久青草视频97国内免费影视| 亚洲一欧洲中文字幕在线| 免费一级毛片不卡不收费| a级成人毛片免费视频高清| 亚洲一卡一卡二新区无人区|