一、使用Tomcat来跑应用
<build>
<plugins>
<plugin>
<groupId>org.apache.tomcat.maven</groupId>
<artifactId>tomcat7-maven-plugin</artifactId>
<version>${tomcat7-maven-plugin.version}</version>
<!-- http://tomcat.apache.org/maven-plugin-2.1/run-mojo-features.html -->
<configuration>
<contextReloadable>true</contextReloadable>
<systemProperties>
<spring.profiles.default>test</spring.profiles.default>
</systemProperties>
<!-- if you want to use test dependencies rather than only runtime -->
<useTestClasspath>true</useTestClasspath>
</configuration>
</plugin>
</plugins>
</build>
<dependency>
<groupId>com.ebiz</groupId>
<artifactId>ebiz-ssi-mysql</artifactId>
<version>1.3</version>
<scope>system</scope>
<systemPath>${project.basedir}/src/main/webapp/WEB-INF/lib/ebiz-ssi-mysql-1.3.jar</systemPath>
</dependency>
三、Deploy依赖到nexus第三方库
1.将deployment用户密码设置为deployment
2.库的设置成可以Redeploy
3.settings.xml servers节点加上以下配置
<server>
<id>thirdparty</id>
<username>deployment</username>
<password>deployment</password>
</server>
install 或 deploy依赖到第三方库
mvn install:install-file -Dpackaging=jar -DgroupId=com.microsoft.sqlserver -DartifactId=sqljdbc4 -Dversion=4.0 -Dfile=sqljdbc4.jar
mvn deploy:deploy-file -Dpackaging=jar -DgroupId=com.microsoft.sqlserver -DartifactId=sqljdbc4 -Dversion=4.0 -Dfile=sqljdbc4.jar -DrepositoryId=thirdparty -Durl=http://nexus:8081/nexus/content/repositories/thirdparty/
1820

被折叠的 条评论
为什么被折叠?



