Introduction to Jenkins and how to deploy Jenkins with Docker

Introduction to Jenkins and how to deploy Jenkins with Docker

1. Related concepts

1.1 Jenkins Concepts:

Jenkins is a powerful application that allows for continuous integration and continuous delivery of projects, regardless of the platform used. It's a free source code that can handle any kind of build or continuous integration. Integration with Jenkins can be used for several testing and deployment techniques. Jenkins is a software that allows continuous integration.

1.2 Jenkins Purpose:

1. Continuously and automatically build/test software projects.
2. Monitor the software opening process, quickly locate and handle problems, and improve opening efficiency.

1.3 Features:

An open source Java language development continuous integration tool that supports CI and CD.

Easy to install, deploy and configure: It can be installed through yum, or by downloading war packages and quickly installed and deployed through docker containers, which facilitates web interface configuration management.

Message notification and test report: Integrated RSS/E-mail to publish build results via RSS or notify via e-mail when the build is completed, and generate JUnit/TestNG test reports.

Distributed build: Support Jenkins to enable multiple computers to build/test together.

File identification: Jenkins can track which build generates which jars, which build uses which version of jars, etc.

Rich plug-in support: Supports extended plug-ins, you can develop tools suitable for your team, such as git, svn, maven, docker, etc.

1.4 Product Release Process:

  • Product design is completed -> Developers develop code -> Testers test functions -> Operations and maintenance personnel release and launch
  • Continuous integration (CI)
  • Continuous delivery
  • Continuous deployment

Docker deployment

docker run -it --name jenkins --restart always --user root -p 10002:8080 -p 50000:50000 -v /var/run/docker.sock:/var/run/docker.sock -v $(which docker):/usr/bin/docker jenkins

The external docker is mapped to the internal docker, so that the docker command can also be used inside the jenkins container

Note that there will be a random password after startup:
example:
1e3180604feb492b9ed9af4e418715d7

If you start it with -it, you can see it in the command window.

Of course you can also enter the container and find it in /var/jenkins_home/secrets/initialAdminPassword.

You need to fill in this password when you open the web page for the first time.

After entering, you will be asked to install plug-ins. I have chosen to install all of them. Of course, you can also only install the recommended ones, or manually choose which plug-ins to install.

Reference: https://hub.docker.com/_/jenkins/

Summarize

The above is the full content of this article. I hope that the content of this article will have certain reference learning value for your study or work. Thank you for your support of 123WORDPRESS.COM. If you want to learn more about this, please check out the following links

You may also be interested in:
  • How to use DockerFile to automatically deploy Java projects in Jenkins
  • Detailed tutorial on deploying Jenkins based on docker
  • Automatically build and deploy using Docker+Jenkins
  • Docker container uses Jenkins to deploy web projects (summary)
  • Detailed explanation of the Docker deployment tutorial for Jenkins beginners

<<:  JavaScript to achieve a simple message board case

>>:  innodb_flush_method value method (example explanation)

Recommend

Briefly understand the MYSQL database optimization stage

introduction Have you ever encountered a situatio...

How to install FastDFS in Docker

Pull the image docker pull season/fastdfs:1.2 Sta...

Detailed explanation of prototypes and prototype chains in JavaScript

Table of contents Prototype chain diagram Essenti...

Explaining immutable values ​​in React

Table of contents What are immutable values? Why ...

Basic usage of wget command under Linux

Table of contents Preface 1. Download a single fi...

How to check the hard disk size and mount the hard disk in Linux

There are two types of hard disks in Linux: mount...

Ubuntu compiles kernel modules, and the content is reflected in the system log

Table of contents 1.Linux login interface 2. Writ...

How to use JavaScript to get the most repeated characters in a string

Table of contents topic analyze Objects of use So...

HTML tag full name and function introduction

Alphabetical DTD: Indicates in which XHTML 1.0 DT...

How to solve the problem of ERROR 2003 (HY000) when starting mysql

1. Problem Description When starting MYSQL, a pro...

Enabling or disabling GTID mode in MySQL online

Table of contents Basic Overview Enable GTID onli...

Pycharm2017 realizes the connection between python3.6 and mysql

This article shares with you how to connect pytho...

Videojs+swiper realizes Taobao product details carousel

This article shares the specific code of videojs+...