jenkins搭建与配置

Jenkins服务搭建及配置 ①概要说明 设备: Windows、Liunx 系统软件: Jenkins安装包 说明: Jenkins服务下载安装及配置,相对应的插件下载方法。 ②下载Jenkins Jenkins下载网站:https://jenkins.io/download/ 根据自己需要安装Jenkins的环境来选择下载的文件,我是在Windows上安装选择Windows 第一步,在官网上下载最新版的64位Wind... 阅读详情

1安装java环境

2下载jenkins.war

3java -jar jenkins.war    (也可放在tomcat里面运行)

4浏览器打开 http://localhost:8080

5填入密码,确定,发现一直卡locading...界面。

vi /root/.Jenkins/updates/default.json  或者c:/用户/Adminstrator/.Jenkins/updates/default.json (看windows/linux)

www.google.com 改为www.baidu.com

只要用来判断本地有没有网络以供后面下载服务,这里由于谷歌被墙了,切到百度

6重启jenkins服务:java -jar jenkins.war,重新打开页面输入密码

7安装推荐的插件

8安装完成后,打开页面系统管理/插件管理

搜索Deploy to container Plugin,勾选安装(主要用来发布war包到tomcat)

9系统管理/全局工具配置 ,可以安装git maven环境,如果有了就不用安装了

10 启动tomcat作为容器

tomcat配置事项

1>server.xml

<?xml version="1.0" encoding="UTF-8"?>
<!--
  Licensed to the Apache Software Foundation (ASF) under one or more
  contributor license agreements.  See the NOTICE file distributed with
  this work for additional information regarding copyright ownership.
  The ASF licenses this file to You under the Apache License, Version 2.0
  (the "License"); you may not use this file except in compliance with
  the License.  You may obtain a copy of the License at
      http://www.apache.org/licenses/LICENSE-2.0
  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
-->
<!-- Note:  A "Server" is not itself a "Container", so you may not
     define subcomponents such as "Valves" at this level.
     Documentation at /docs/config/server.html
 -->
<Server port="8005" shutdown="SHUTDOWN">
  <Listener className="org.apache.catalina.startup.VersionLoggerListener" />
  <!-- Security listener. Documentation at /docs/config/listeners.html
  <Listener className="org.apache.catalina.security.SecurityListener" />
  -->
  <!--APR library loader. Documentation at /docs/apr.html -->
  <Listener className="org.apache.catalina.core.AprLifecycleListener" SSLEngine="on" />
  <!-- Prevent memory leaks due to use of particular java/javax APIs-->
  <Listener className="org.apache.catalina.core.JreMemoryLeakPreventionListener" />
  <Listener className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener" />
  <Listener className="org.apache.catalina.core.ThreadLocalLeakPreventionListener" />
  <!-- Global JNDI resources
       Documentation at /docs/jndi-resources-howto.html
  -->
  <GlobalNamingResources>
    <!-- Editable user database that can also be used by
         UserDatabaseRealm to authenticate users
    -->
    <Resource name="UserDatabase" auth="Container"
              type="org.apache.catalina.UserDatabase"
              description="User database that can be updated and saved"
              factory="org.apache.catalina.users.MemoryUserDatabaseFactory"
              pathname="conf/tomcat-users.xml" />
  </GlobalNamingResources>
  <!-- A "Service" is a collection of one or more "Connectors" that share
       a single "Container" Note:  A "Service" is not itself a "Container",
       so you may not define subcomponents such as "Valves" at this level.
       Documentation at /docs/config/service.html
   -->
  <Service name="Catalina">
    <!--The connectors can use a shared executor, you can define one or more named thread pools-->
    <!--
    <Executor name="tomcatThreadPool" namePrefix="catalina-exec-"
        maxThreads="150" minSpareThreads="4"/>
    -->
 
    <!-- A "Connector" represents an endpoint by which requests are received
         and responses are returned. Documentation at :
         Java HTTP Connector: /docs/config/http.html
         Java AJP  Connector: /docs/config/ajp.html
         APR (HTTP/AJP) Connector: /docs/apr.html
         Define a non-SSL/TLS HTTP/1.1 Connector on port 8080
    -->
    <Connector port="9090" protocol="HTTP/1.1"
               connectionTimeout="20000"
               redirectPort="8443" />
    <!-- A "Connector" using the shared thread pool-->
    <!--
    <Connector executor="tomcatThreadPool"
               port="8080" protocol="HTTP/1.1"
               connectionTimeout="20000"
               redirectPort="8443" />
    -->
    <!-- Define a SSL/TLS HTTP/1.1 Connector on port 8443
         This connector uses the NIO implementation. The default
         SSLImplementation will depend on the presence of the APR/native
         library and the useOpenSSL attribute of the
         AprLifecycleListener.
         Either JSSE or OpenSSL style configuration may be used regardless of
         the SSLImplementation selected. JSSE style configuration is used below.
    -->
    <!--
    <Connector port="8443" protocol="org.apache.coyote.http11.Http11NioProtocol"
               maxThreads="150" SSLEnabled="true">
        <SSLHostConfig>
            <Certificate certificateKeystoreFile="conf/localhost-rsa.jks"
                         type="RSA" />
        </SSLHostConfig>
    </Connector>
    -->
    <!-- Define a SSL/TLS HTTP/1.1 Connector on port 8443 with HTTP/2
         This connector uses the APR/native implementation which always uses
         OpenSSL for TLS.
         Either JSSE or OpenSSL style configuration may be used. OpenSSL style
         configuration is used below.
    -->
    <!--
    <Connector port="8443" protocol="org.apache.coyote.http11.Http11AprProtocol"
               maxThreads="150" SSLEnabled="true" >
        <UpgradeProtocol className="org.apache.coyote.http2.Http2Protocol" />
        <SSLHostConfig>
            <Certificate certificateKeyFile="conf/localhost-rsa-key.pem"
                         certificateFile="conf/localhost-rsa-cert.pem"
                         certificateChainFile="conf/localhost-rsa-chain.pem"
                         type="RSA" />
        </SSLHostConfig>
    </Connector>
    -->
    <!-- Define an AJP 1.3 Connector on port 8009 -->
    <Connector port="8009" protocol="AJP/1.3" redirectPort="8443" />
 
    <!-- An Engine represents the entry point (within Catalina) that processes
         every request.  The Engine implementation for Tomcat stand alone
         analyzes the HTTP headers included with the request, and passes them
         on to the appropriate Host (virtual host).
         Documentation at /docs/config/engine.html -->
    <!-- You should set jvmRoute to support load-balancing via AJP ie :
    <Engine name="Catalina" defaultHost="localhost" jvmRoute="jvm1">
    -->
    <Engine name="Catalina" defaultHost="localhost">
      <!--For clustering, please take a look at documentation at:
          /docs/cluster-howto.html  (simple how to)
          /docs/config/cluster.html (reference documentation) -->
      <!--
      <Cluster className="org.apache.catalina.ha.tcp.SimpleTcpCluster"/>
      -->
      <!-- Use the LockOutRealm to prevent attempts to guess user passwords
           via a brute-force attack -->
      <Realm className="org.apache.catalina.realm.LockOutRealm">
        <!-- This Realm uses the UserDatabase configured in the global JNDI
             resources under the key "UserDatabase".  Any edits
             that are performed against this UserDatabase are immediately
             available for use by the Realm.  -->
        <Realm className="org.apache.catalina.realm.UserDatabaseRealm"
               resourceName="UserDatabase"/>
      </Realm>
      <Host name="localhost"  appBase="webapps"
            unpackWARs="true" autoDeploy="true">
        <!-- SingleSignOn valve, share authentication between web applications
             Documentation at: /docs/config/valve.html -->
        <!--
        <Valve className="org.apache.catalina.authenticator.SingleSignOn" />
        -->
        <!-- Access log processes all example.
             Documentation at: /docs/config/valve.html
             Note: The pattern used is equivalent to using pattern="common" -->
                  
                  
        <Valve className="org.apache.catalina.valves.AccessLogValve" directory="logs"
               prefix="localhost_access_log" suffix=".txt"
               pattern="%h %l %u %t &quot;%r&quot; %s %b" />
      </Host>
    </Engine>
  </Service>
</Server>
 

注意context不用配置

2>tomcat-users.xml

<?xml version="1.0" encoding="UTF-8"?>
<!--
  Licensed to the Apache Software Foundation (ASF) under one or more
  contributor license agreements.  See the NOTICE file distributed with
  this work for additional information regarding copyright ownership.
  The ASF licenses this file to You under the Apache License, Version 2.0
  (the "License"); you may not use this file except in compliance with
  the License.  You may obtain a copy of the License at
      http://www.apache.org/licenses/LICENSE-2.0
  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
-->
<tomcat-users xmlns="http://tomcat.apache.org/xml"
              xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
              xsi:schemaLocation="http://tomcat.apache.org/xml tomcat-users.xsd"
              version="1.0">
<!--
  NOTE:  By default, no user is included in the "manager-gui" role required
  to operate the "/manager/html" web application.  If you wish to use this app,
  you must define such a user - the username and password are arbitrary. It is
  strongly recommended that you do NOT use one of the users in the commented out
  section below since they are intended for use with the examples web
  application.
-->
<!--
  NOTE:  The sample user and role entries below are intended for use with the
  examples web application. They are wrapped in a comment and thus are ignored
  when reading this file. If you wish to configure these users for use with the
  examples web application, do not forget to remove the <!.. ..> that surrounds
  them. You will also need to set the passwords to something appropriate.
-->
                             <role rolename="tomcat"/>
                            
<!-->
  <role rolename="tomcat"/>
  <role rolename="role1"/>
  <user username="tomcat" password="" roles="tomcat"/>
  <user username="both" password="<must-be-changed>" roles="tomcat,role1"/>
  <user username="role1" password="<must-be-changed>" roles="role1"/>-->
  <role rolename="manager-gui"/>  
  <role rolename="manager-script"/>  
  <role rolename="manager-jmx"/>  
  <role rolename="manager-status"/>
  <role rolename="admin"/>
  <role rolename="manager"/>
  
  <user username="admin" password="kaicom2017" roles="tomcat,admin,manager,manager-script,manager-jmx,manager-status"/>
</tomcat-users>
 

 

添加一些权限给用户,供后面打包发布

3>tomcat下work目录删除重新启动

 

11新建项目,选择自由风格的项目

 

 

 

(2)搭建jenkins和配置jenkins使用gitab更新代码 搭建jenkins和配置jenkins使用gitlab更新代码 阅读详情

相关推荐

配置表测试框架搭建-⑧Jenkins搭建集成配置表检查

文章目录前言安装安装Java-JDK8安装Jenkins安装Allure commandline实践一、初始化Jenkins二、安装Jenkins-allure插件三、新建任务运行结语 前言 Jenkins的搭建网上有很多教程,官网也有,点击跳转,结合自己情况搭建,接下来我是用云服务器进行搭建,如果公司有提供可以直接上手,或者上阿里云、腾讯云买个服务器。 环境: OS:Linux VM-20-8-ubuntu 5.4.0-42-generic 安装 安装Java-JDK8 命令的jdk版本和路径可以自行调整

游戏测试-AJiian的博客 9576

Jenkins文件夹下没有default.json文件

Jenkins文件夹下没有default.json文件

weixin_52022790的博客 3551

jenkins的default文件

主要是为了安装插件时,替换资源源,将国外的地址替换成国内的,这样安装jenkins插件时会快些,不容易失败。放在\.jenkins\updates目录中。

docker安装Jenkins

目录 0.前言 1. 查询jenkins镜像 2. 安装配置jenkins 2.1 拉取jenkins镜像 2.2 创建挂载目录 2.3 启动jenkins 2.4 修改配置文件 2.5 重启容器 3 打开http://localhost:8081/ 3.1 获取初始密码并登陆 3.2 用新密码重新登陆 0.前言 安装docker mac下安装docker 1. 查询jenkins镜像 docker search jenkins 2. 安装配置jenkins .

Adele的专栏 1235

宏基因组分析|完整分析流程梳理

今天先从最基础的全流程框架说起,无论是刚接触的萌新,还是想查漏补缺的同行,都能找到有用的信息。

weixin_70911870的博客 3182

计算机视觉研究方向有哪些?什么方向最好出论文创新点

计算机视觉(CV)是人工智能中一个活跃且应用广泛的研究领域,旨在让计算机理解和处理图像与视频。其主要研究方向包括图像分类、目标检测、图像分割、姿态估计、图像生成与重建、视频理解、三维视觉和跨模态视觉理解。这些方向不仅涉及基础理论,还紧密联系实际应用,适合发表论文和实现项目落地。为了在CV领域取得创新,建议关注跨模态学习、小样本学习、图像生成模型的控制与轻量化、视频分析以及医学图像分析等方向。此外,通过阅读顶会论文、复现SOTA方法、模型微调和数据集创新等方式,可以有效切入研究并产生有价值的成果。

OpenCVtuxiang的博客 3578

【Jenkins】之配置国内镜像加速

一、Jenkins 插件下载流程 1、default.json 文件 首先,Jenkins 会读取 工作目录(默认为/var/jenkins_home)下的 /updates/default.json 文件内容,里面包含了插件更新和下载的地址。下面是部分配置内容: { "connectionCheckUrl": "http://www.google.com/", "core": { "buildDate": "Mar 15, 2022", "name": "core", "

王廷云的博客 1万+

深入解析Vivado FIFO的Standard与FWFT模式:性能对比与应用场景

本文深入解析了Vivado FIFO的Standard与FWFT两种工作模式的核心差异。通过对比数据就绪时机、读延迟、控制逻辑和有效深度等关键特性,并结合图像处理、数据包转发等典型应用场景,为FPGA设计者提供了清晰的选择依据和实战配置指南,帮助优化数据流性能与设计效率。

weixin_29219189的博客 267

Jenkins快速入门部署+实践

直接从http://mirrors.jenkins-ci.org/war/latest/jenkins.war 下载最新的war包,然后解压到某个固定目录就算安装完成了

软件测试技术交流分享 798

弥散圆以及最大弥散圆

1弥散圆的形成? 原本景物中的一点应该经过透镜本应该也是一点才对。但是因为离焦,球差的存在,最终成像会投影成一个光斑圆圈。越小越清晰,越大就互相干涉变得越模糊。 同时人们规定二零最大弥散圆,就是人眼能够感受清晰模糊的一个边界,直径大于它,感受到模糊;直径小于它,感受不到模糊。 下面分别是离焦(左),球差(右)。 2弥散圆大小怎么计算呢? ,f为焦距;<1> ,D为光圈有效孔径;<2> F=f/D; <3> 3条公式合并可得出: ...

camerall 3131

Jenkins配置基于角色的项目权限管理

Jenkins配置基于角色的项目权限管理 一.安装插件 首先需要安装三方插件:Role-Based Strategy 1.系统管理   2.插件管理   3.可选插件安装(搜索Role-Based Strategy)   4.插件安装成功后重启jenkins Service jenkins restart 二.安装插件后进行系统配置 进入系统管理,后续步骤如下:

蓝凌的博客 2790

知识图谱设计简记

知识图谱是一种语义化的知识表示框架,通过实体-关系-属性三元组形式表达现实世界关联。其核心价值在于关联化整合数据、支持可解释性推理和赋能智能化应用。知识图谱可分为通用型和领域型两类,基本构成包括实体、关系、属性等基础元素,以及本体和实例等架构层元素。设计方法主要有自上而下、自下而上和混合式三种,需遵循业务导向、一致性等原则。在建模时需要明确属性与实体的判断标准,规范处理关系的方向性与对称性,并合理构建多重关系。主流技术框架如RDF和属性图体系均支持多重关系建模,选择需考虑业务需求。本体作为知识图谱的概念骨架

生活在别处 392

Linux搭建Jenkins及配置

背景 自己搭建Jenkins时,在网上看到各种各样的文档,实践操作过程中发现其实步骤很简单,具体不懂的地方可在网上搜索。本文安装Jenkins的方法,没有安装tomcat,也可以通过tomcat安装Jenkins,具体自行在网上搜索。 搭建步骤 下载安装 sudo wget -O /etc/yum.repos.d/jenkins.repo https://pkg.jenkins.io/re...

爱生活,爱学习 9934

基于NB-IoT的智慧路灯监控系统(NB-IoT专栏—实战篇1:项目简介)

基于NB-IoT技术的城市道路智慧路灯监控系统,在每个照明节点上安装一个集成了NB-IoT模组的单灯控制器,单灯控制器再经运营商的网络,与路灯控制平台实现双向通信,路灯控制平台直接对每个灯进行控制,包括开关灯控制、光照检测、自动调节明暗、电耗分析等操作。

不脱发的程序猿 5万+

嵌入式工程师必学(118):MCU的硬件定时器和中断

大多数微处理器都有一个或多个可编程硬件定时器,这些定时器包括对中断的支持。可以有不同类型的计时器,用于不同的应用程序。例如,LPC1768 具有四个 32 位通用定时器、一个看门狗定时器、一个重复中断定时器、一个系统滴答定时器、一个正交编码器接口、6 个 PWM 输出和一个支持中断的实时时钟。硬件定时器用于计时和计数作,允许处理器在 timer 进程运行时继续执行其他进程。硬件定时器是一种使用 clock 信号来增加 register 的电路。

码农17年的博客 221

jenkins的搭建与配置

文章目录搭建jenkins 搭建jenkins 将Jenkins的war包移动到tomcat的webapps下 [root@localhost ~]# mv jenkins.war /usr/local/tomcat/webapps/ [root@localhost ~]# ls /usr/local/tomcat/webapps/ docs examples host-manager jenkins jenkins.war manager ROOT 访问jenkins网站并解锁 [root@

h1228322088的博客 511

Statistics and Machine Learning Toolbox

Statistics and Machine Learning Toolbox(带书签),MATLAB统计学习工具

jenkins 安装插件失败_自动化部署—Jenkins环境搭建和配置

=================交个作业:hello-world级的自动化部署(Maven+Git+Docker+Jenkins),内容稍微有点儿多,分两篇,这是第一篇——环境搭建和配置。=================环境:CentOS7-64已安装JAVA8(Jekins需要)安装Maven:wget https://mirror.bit.edu.cn/apache/maven/...

weixin_39723248的博客 779

inori mmd 7z

楪祈的模型资源....................................................................................................................................................................................................................

jdk-8u144-linux-x64.tar.gz.

该资源为搭建Linux系统Java环境用,资源的后缀为tar.gz格式的压缩包

Windows系统下搭建Jenkins服务和邮件配置

一、此文章仅记录Windows系统下搭建Jenkins服务和邮件配置,本文使用的是QQ邮箱,其他邮箱配置方法基本一致。二、从 Jenkins 2.357(2022 年 6 月 28 日发布)以及 2022 年 9 月发布的 LTS(长期支持)版本开始,官方要求使用 Java 11。如果想要使用 JDK 1.8,就需要安装 Jenkins 2.357 版本之前的版本,因为这些旧版本是基于 Java 8 构建和测试的,能够在 Java 8 环境下正常运行。

weixin_44475572的博客 1785

ET2012新版免狗免安装绿色软件

ET2012新版免狗免安祖昂绿色软件。,新界面,新视觉,

一文看懂Jenkins环境搭建及配置

本文主要讲解了Jenkins环境部署及相关配置,同时给出了常用流水线管理示例。

专注IT技术。 1564

Docker 搭建 SonarQube + Jenkins 配置

Docker 搭建 SonarQube + Jenkins 配置

weixin_41285522的博客 858

[完整版]Windows下搭建及配置jenkins(上)

[完整版]Windows下搭建及配置jenkins(上)背景简介jenkins安装下载安装必要设置账户创建插件安装权限管理总结 背景简介 简单说一下这么做的初衷。目前公司做安全隔离,开发测试区环境的服务器全部不通外网,导致原先部署的jenkins无法实现包的更新,因此就有了这个想法, 在本地台式机上搭建一套jenkins,然后利用ssh完成远端部署,并利用jenkins的role权限隔离,完成开发、测试环境部署分割,可以大大提升工作效率。 由于使用的是win环境,因此在部署和配置过程中遇到不少坑点,简单写篇

SchrodingerY-博客 2104

Jenkins和Gitlab搭建及配置管理

一、环境配置 操作系统:CentOS-7.3 1611 x86_64 系统组件:服务器全安装版 所需安装包: Jenkins安装包:jenkins-2.150.3-1.1.noarch.rpm GitLab安装包:gitlab-ce-11.11.7-ce.0.el7.x86_64.rpm Jenkins插件安装包s CentOS-7.3 1611 x86_64安装IS...

Your Dream Started 5669

手把手教你搭建和配置Jenkins环境

搭建Jenkins,首先得安装Jenkins,安装的问题就不说了,一般第一次安装完成后,服务会直接在浏览器中运行,网址:http://localhost:8080。然后新建一个用户,登录    接下来就是如何配置Jenkins,我们现在做的系统是.Net平台的,所以配置的Jenkins适用于.Net,至于说Java的配置,暂时还不涉及,就不在这儿讲了。  配置SVN并新建一个简单的网站

令仔很忙 1万+

Jenkins搭建及自动化脚本配置等

Jenkins是一个独立的开源自动化服务器,可用于自动执行与构建、测试、交付或部署软件相关的各种任务。例如:检查代码、构建编译、运行测试、结果记录和测试统计等都是自动完成的。 使用Jenkins之前需要先安装Java环境。 1、安装Jenkins 官网地址: https://www.jenkins.io/ Jenkins安装首页面: 安装完成后直接弹出浏览器界面,默认访问地址:localhost:8080 输入管理员密码: 路径:C:\Windows\system32\config\systempro

石头缝里的小松鼠(AlySam) 1702

[搭建完整jenkins发布环境一]Centos环境下配置jenkins并启动

环境准备 java8 官方下载tar包,解压并配置环境变量(我放在/usr/local路径下)。安装jdk太基础,各自百度吧。 二、jenkins安装 2.1 rpm安装jenkins 点击下载rpm 如果下载失效,就到官网下载,很简单。安装命令如下: rpm -ih jenkins-2.150.2-1.1.noarch.rpm 简单介绍下安装后的得目录 /etc/init.d/jenk...

kouryoushine的博客 3984
上一篇: HBase2.0单机搭建
下一篇: HBase引入phoenix
programmeryu
博客等级 码龄11年 23粉丝 67原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

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

抵扣说明:

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

余额充值
⌂ 换网址