Continuous Delivery - Getting Started with Pipeline

Pipeline is the core feature of Jenkins2.X, which helps Jenkins realize the transformation from CI to CD and DevOps.
Pipeline is a set of plugins that enables Jenkins to implement and implement continuous delivery pipelines. A continuous delivery pipeline (CD Pipeline) is an automated representation of the complete process of moving software from the version control stage to delivery to users or customers. Every change to the software (committed to the source code management system) goes through a complex process before it can be released.

Pipeline provides a set of extensible tools that can achieve the purpose of Pipeline as Code (Jenkinsfile is stored in the project's source code repository) through the Pipeline Domain Specific Language (DSL) syntax.

Basic Concepts in Pipeline

Stage, a Pipeline can be divided into several Stages, each Stage represents a group of operations, such as: "Build", "Test", "Deploy". Stage is a logical grouping concept that can span multiple Nodes

Node, a Node is a Jenkins node, or Master, or Agent, which is the specific operating environment for executing Step.

Steps are the most basic unit of operation, ranging from creating a directory to building a Docker image.

Pipeline creation and configuration

Create a new Jenkins task and select Pipeline in the task type. Fill in the Pipeline Script dialog with the Pipeline task code.

Run the Pipeline task.

Run Pipeline tasks from the codebase

In addition to adding the Pipeline code running task directly in the Jenkins UI, you can also save the code to the code repository, and then run the Pipeline task by specifying the code location. The operation steps are as follows:
1. Create a new Jenkins task and select Pipeline in the task type.
2. Select Pipeline script from SCM in the Jenkins Pipeline task, then add the git source address, and fill in the address of the Jenkinsfile to be run in Script Path.
3. Run the Pipeline task through the codebase.
4.

Save the Pipeline configuration and run the task.

Pipeline, in short, is a workflow framework running on Jenkins, which connects tasks that originally run independently on a single or multiple nodes, and realizes complex process orchestration and visualization that is difficult to complete with a single task.

⬇️ Click "Read the original text" to improve the core competitiveness of the test!
Original link

More technical articles to share

Guess you like

Origin blog.csdn.net/hogwarts_2022/article/details/124267062
Recommended