24 Kasım 2021 Çarşamba

Jenkinsfile

Giriş
Jenkins UI yerine kodla Jenkins pipeline oluşturmak içindir.  Scripted (groovy) veya declarative olarak yazılabilir. 

İki çeşit pipeline var
1. Build pipeline. Şeklen şöyle

2. Release pipeline. Şeklen şöyle

Environment Variables
Adres şöyle
localhost::8080/env-vars.html
GitHub
3 tane kontrol var. Bunlar şöyle
1. continuous-integration/jenkins/branch
Branch için çalışır

2. continuous-integration/jenkins/pr-head
Açıklaması şöyle
It builds the head commit of the PR branch (rather than merge it into the base branch, then build that).
3. continuous-integration/jenkins/pr-merge
Açıklaması şöyle
... the continuous-integration/jenkins/pr-merge is triggered which runs a Jenkins pipeline to build the code and perform unit tests. This allows us to prevent the PR from being merged into master if the unit tests fail.

1. Scripted Pipeline - Kullanmayın
Scripted Pipeline yazısına taşıdım

2. Declarative Pipeline
Declarative Pipeline yazısına taşıdım

Hiç yorum yok:

Yorum Gönder