[Jenkins] Scripted Pipeline lesson 6: Stage _ Input
Chúng tạo 1 step và require user input mới action tiếp Sau đó ấn build: Như bài trên thì nó sẽ chờ mãi Giờ nếu bạn muốn nếu sau 1 thời gian nhất định nếu ko có ai input thì abort
Trình bày các công nghệ CLOUD một cách dễ hiểu.
Chúng tạo 1 step và require user input mới action tiếp Sau đó ấn build: Như bài trên thì nó sẽ chờ mãi Giờ nếu bạn muốn nếu sau 1 thời gian nhất định nếu ko có ai input thì abort
Bạn tạo 1 Pipeline: Bạn thấy các công việc sẽ được chạy đồng thời cùng lúc failFast: true thì mình có tìm được giải thích:From Documentation: You can force your parallel stages to all be aborted when one of them fails, by adding failFast true to the stage containing the parallel.https://stackoverflow.com/questions/58026189/how-to-use-failfast-in-dynamic-pipeline-in-jenkins
ở jenkins pipeline thì mình cũng có giới thiệu về when 1) Condition 2) Branch 3) building Tag and tag 4) changelog – commit không giống như bài changelog ở Jenkins Pipelinehttps://nimtechnology.com/2021/10/30/jenkins-lesson-5-condition-when-in-pipeline-jenkins/#changelog_8211_commit Để lấy được changeLog chú ta cần dùng changeSets. changeSets a list of changesets coming from distinct SCM checkouts; each has a kind and is a list…
Read More “[Jenkins] Scripted Pipeline lesson 4: Stage _ When” »
Mình có 1 con để lab cho mọi người và mình cũng có hướng dẫn cài ở link dưới Hôm đó server mất điện các bạn ạ.và sau start k8s lên thì nó lỗi. Rồi redeploy lại
1) Error_Retry 1.1) retry into stage 1.2 ) build stage inside a retry block Ở các hình bên dưới nó sẽ try cả stage luôn nhé 1.3) node inside a retry block node được retry 3 lần vì error 2) Timeout 2.1) timeout inside stage 2.2 ) build stage inside a retry timeout 2.3 )…
Read More “[jenkins] Scripted Pipeline lesson 3: Stage _ Options” »
Đầu tiền bạn cần cài đặt plugin sau: 1) Prepare 1.1) install Plugin Docker pipeline 1.2) approve Sau đó khi run build nó sẽ cần bạn approve 1 số thứ 1.3) Needing vm jenkins that have docker Sau đó cấu hình kết nối giữa jenkins master và agent. 2) Docker Images GIờ hình ta đã…
Install Jenkins Install docker Add user Jenkins group docker Here we need to enter the password. To obtain the password, run the following command in the terminal to locate the password that is stored in the initialAdminPassword file.
1) Introduction Alo! Scripted Pipeline khác j với với Jenkins Pipeline?Thằng nào ngon hơn? Mấy cái câu này bạn cứ dò google trên đó họ phân tích nhiều lắm rồi. Và để tạo ra sự khác biệt mình ko giải thích mà đi vào bài luôn.Mình nghĩ sau khi các đọc nát google thì hay…
Read More “[jenkins] Scripted Pipeline lesson 1: Introduction” »
Ở các bài trước thì bạn sẽ thấy script pipeline của mình khá là dài. Bài này script pipeline siêu ngắn. Bạn sẽ thấy là script sẽ thấy call global function execBuildOrDeploy() https://github.com/mrnim94/pipeline-shared-lib/blob/master/vars/execBuildOrDeploy.groovy Chúng ta sẽ định nghĩ pipeline Script trong method Call Save lại và coi thành phả nào
Như giới thiệu ở bài đầu tiên, thư mục resources chưa các file ko phải là Groovy Trong resources mình để 1 file Json https://github.com/mrnim94/pipeline-shared-lib/blob/master/resources/com/acceleratedskillup/request.json giờ chúng ta có script như sau: Giờ save material reference about libraryResoucehttps://www.jenkins.io/doc/book/pipeline/shared-libraries/#loading-resourceshttps://www.jenkins.io/doc/pipeline/steps/workflow-cps-global-lib/ Chúng ta có vẫn đề là bạn thấy jenkins master sẽ control jenkins agent.nhưng mà jenkins agent…
Read More “[Jenkins] Share Libraries 8: Loading Resources” »