Skip to content

Commit 8b51955

Browse files
Jaime Salas ZancadaJaime Salas Zancada
authored andcommitted
added introduction notes
1 parent e409a19 commit 8b51955

File tree

1 file changed

+90
-0
lines changed

1 file changed

+90
-0
lines changed

03-cd/01-jenkins/notes.md

Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
# ¿Qué es Jenkins?
2+
3+
> The leading open source automation server, Jenkins provides hundreds of plugins to support building, deploying and automating any project.
4+
5+
# ¿Qué es una Pipeline?
6+
7+
> _A continuous delivery (CD) pipeline_ is an automated expression of your process for getting software from version control right through to your users and customers. Every change to your software (committed in source control) goes through a complex process on its way to being released. This process involves building the software in a reliable and repeatable manner, as well as progressing the built software (called a "build") through multiple stages of testing and deployment.
8+
9+
# ¿Qué es una Jenkins Pipeline?
10+
11+
> Es un conjunto de plugins que soportan la implementación e integración de _continous delivery pipelines_ en Jenkins
12+
13+
* `Pipeline` provee de un conjunto extensible de herramientas para modelar `simple-to-complex delivery pipelines` "cómo código" via [Pipeline domain-specific language (DSL) syntax]('https://www.jenkins.io/doc/book/pipeline/syntax/')
14+
15+
* La definición de una `Jenkins Pipeline` se escribe en un fichero de texto `Jenkinsfile`.
16+
17+
## Benificios de Pipeline cómo código
18+
19+
* Crea una _Pipeline build process_ para todas las ramas y peticiones de integración (pull requests).
20+
* Revisión de código e iteración sobre la Pipeline
21+
* Posibilidad de auditar los cambios a lo largo de la historia de la Pipeline.
22+
* Una única fuente de verdad sobre la Pipeline
23+
24+
# Declarative vs Scripted Pipeline syntax
25+
26+
* Un `Jenkinsfile` se puede escribir de dos maneras - **Declarative y Scripted**
27+
28+
* La `Declarative Pipeline` es más reciente y tiene cómo características:
29+
- provee características sintácticas más ricas que sintaxis de la `Scripted Pipeline`
30+
- está diseñada para escribir y leer la Pipeline fácilmente
31+
32+
# ¿Por qué Pipeline
33+
34+
* __Code:__ Pipelines are implemented in code and typically checked into source control, giving teams the ability to edit, review, and iterate upon their delivery pipeline
35+
* __Durable:__ Pipelines can survive both planned and unplanned restarts of the Jenkins controller.
36+
* __Pausable:__ Pipelines can optionally stop and wait for human input or approval before continuing the Pipeline run.
37+
* __Versatile:__ Pipelines support complex real-world CD requirements, including the ability to fork/join, loop, and perform work in parallel.
38+
* __Extensible:__ The Pipeline plugin supports custom extensions to its DSL footnote:dsl:[] and multiple options for integration with other plugins.
39+
40+
# Pipeline concepts
41+
42+
## Pipeline
43+
44+
Una `Jenkins Pipeline` es un modelo definido por un usuario de una `CD pipeline`. El código de la `Pipeline` define todo el proceso de `build`, el cual suele incluir escenarios para construir una aplicación, testear y después distribuirla.
45+
46+
> _pipeline_ es un bloque fundamental dentro de _Declarative Pipeline syntax_
47+
48+
## Node
49+
50+
Un `node` es una máquina la cual es parte de un entorno Jenkins y es capaz de ejecutar un nodo.
51+
52+
> Un _node_ es parte de una _Scripted Pipeline syntaxt_
53+
54+
## Stage
55+
56+
* Un bloque `stage` define coneceptualmente un subconjunto de tareas distintas ejecutadas a través de la Pipeline:
57+
- Build
58+
- Test
59+
- Deploy
60+
61+
## Step
62+
63+
* Una tarea única. Fundamentalmente, un `step` le dice a Jenkins que hacer en un punto particular en el tiempo.
64+
65+
# Pipeline syntax overview
66+
67+
## Declarative Pipeline fundamentals
68+
69+
```groovy
70+
pipeline {
71+
agent any // [1]
72+
stages {
73+
stage('Build') { // [2]
74+
steps {
75+
// [3]
76+
}
77+
}
78+
stage('Test') {
79+
steps {
80+
//
81+
}
82+
}
83+
stage('Deploy') {
84+
steps {
85+
//
86+
}
87+
}
88+
}
89+
}
90+
```

0 commit comments

Comments
 (0)