jenkins

  1. nexus

    1. docker运行,管理账号admin,初始密码在/nexus-data/admin.password中
    2. 初始化时可设置为匿名访问,发布代码时需配置账号
      <!--项目pom文件-->
      <?xml version="1.0" encoding="UTF-8"?>
      <project 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/maven-4.0.0.xsd">
          <!--私服仓库,发布代码-->
          <distributionManagement>
              <repository>
                  <id>maven-releases</id>
                  <name>Nexus Release Repository</name>
                  <url>http://192.168.0.100:8008/repository/maven-releases/</url>
              </repository>
              <snapshotRepository>
                  <id>maven-snapshots</id>
                  <name>Nexus Snapshot Repository</name>
                  <url>http://192.168.0.100:8008/repository/maven-snapshots/</url>
              </snapshotRepository>
          </distributionManagement>
      </project>
      
      
      <!--maven setting-->
      <?xml version="1.0" encoding="UTF-8"?>
      
      <settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
                xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
        <servers>
          <!--私服凭证,发布代码需要-->   
          <server>
            <id>maven-releases</id>
            <username>admin</username>
            <password>admin</password>
          </server>
          <server>
            <id>maven-snapshots</id>
            <username>admin</username>
            <password>admin</password>
          </server>
        </servers>
      
        <mirrors>
         	<mirror>
         			<!--下载jar包-->
      		    <id>nexus</id>
      		    <!--<mirrorOf>*</mirrorOf>-->
      		    <mirrorOf>central</mirrorOf>
      		    <name>nexus maven</name>
      		    <url>http://192.168.0.100:8008/repository/maven-public/</url>
      		</mirror>
           
          <!-- 阿里云仓库 -->
      		<mirror>
      		    <id>alimaven</id>
      		    <mirrorOf>central</mirrorOf>
      		    <name>aliyun maven</name>
      		    <url>http://maven.aliyun.com/nexus/content/repositories/central/</url>
      		</mirror>
      
      		<!-- 中央仓库1号 -->
      		<mirror>
      		    <id>repo1</id>
      		    <mirrorOf>central</mirrorOf>
      		    <name>Human Readable Name for this Mirror.</name>
      		    <url>http://repo1.maven.org/maven2/</url>
      		</mirror>
      
      		<!-- 中央仓库2号 -->
      		<mirror>
      		    <id>repo2</id>
      		    <mirrorOf>central</mirrorOf>
      		    <name>Human Readable Name for this Mirror.</name>
      		    <url>http://repo2.maven.org/maven2/</url>
      		</mirror>
        </mirrors>
        <profiles>
          <profile>
          	<id>jdk-1.8</id>
          	<activation>
          		<activeByDefault>true</activeByDefault>
          		<jdk>1.8</jdk>
          	</activation>
          	<properties>
          		<maven.compiler.source>1.8</maven.compiler.source>
          		<maven.compiler.target>1.8</maven.compiler.target>
          		<maven.compiler.compilerVersion>1.8</maven.compiler.compilerVersion>
          	</properties>
          </profile>
      
          <!--下载jar包-->
          <profile>    	
          	<id>local-nexus</id>
          	<repositories>
      	     	<repository>
      	        <id>local-nexus</id>
      	        <url>http://192.168.0.100:8008/repository/maven-public/</url>
      	        <releases>
      	          <enabled>true</enabled>
      	        </releases>
      	        <snapshots>
      	          <enabled>true</enabled>
      	        </snapshots>
      	      </repository>
          	</repositories>
          </profile>
        </profiles>
      	
      	<activeProfiles>
      			<!--
      			<activeProfile>jdk-1.8</activeProfile>
            <activeProfile>local-nexus</activeProfile>
            -->
        </activeProfiles>
      </settings>
      

       

  2. jenkins

    1. 插件默认安装,失败重试几次
    2. 工作空间在/root/.jenkins/workspace/下
    3. 可安装语言插件(Locale)
    4. 可安装权限管理插件(Role-based Authorization Strategy)
    5. 可安装远程部署软件(Publish Over SSH)

 

 

 

 

 

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值