2021-07-12-Jenkins在Linux下安装

安装#

  1. sudo wget -O /etc/yum.repos.d/jenkins.repo https://pkg.jenkins.io/redhat-stable/jenkins.repo

  2. sudo rpm –import https://pkg.jenkins.io/redhat-stable/jenkins.io.key

  3. sudo yum install jenkins

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    jenkins/primary_db                                                                                                                                                              |  36 kB  00:00:00     
    Resolving Dependencies
    --> Running transaction check
    ---> Package jenkins.noarch 0:2.277.1-1.1 will be installed
    --> Finished Dependency Resolution

    Dependencies Resolved

    ==============================================================================================================================================================================================================
    Package Arch Version Repository Size
    ==============================================================================================================================================================================================================
    Installing:
    jenkins noarch 2.277.1-1.1 jenkins 67 M

    Transaction Summary
    ==============================================================================================================================================================================================================
    Install 1 Package
  4. sudo yum install jenkins java-1.8.0-openjdk-devel

安装JDK

  1. java -version

    1
    2
    3
    openjdk version "1.8.0_282"
    OpenJDK Runtime Environment (build 1.8.0_282-b08)
    OpenJDK 64-Bit Server VM (build 25.282-b08, mixed mode)
  2. sudo systemctl daemon-reload
    加载新的unit 配置文件

作者

lxmuyu

发布于

2022-02-17

更新于

2022-02-17

许可协议