Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Feedback Loop implementation in CI/CD pipeline using Jenkins and kubernetes

Currently I am trying to implement CI/CD pipeline using the DevOps automation tools like Jenkins and kubernetes. And I am using these for deploying my micro services creates using spring boot and maven projects.

Now I am successfully deployed my spring boot micro services using Jenkins and Kubernetes. I am deployed to different namespaces using kubernetes. When I am committing , one post commit hook will work from my SVN repository. And that post commit hook will trigger the Jenkins Job.

My Confusion

When I am implementing the CI/CD pipeline , I read about the implementation of feed back loops in pipeline. Here I had felt the confusion that , If I need to use the implementation of Feedback Loops then which are the different ways that I can follow here ?

Can anyone suggest me to find out any useful documentations/tutorials for implementing the feed back loops in CI/CD pipeline please?

like image 525
Jacob Avatar asked Aug 27 '19 06:08

Jacob


People also ask

How CI CD works with Kubernetes?

CI/CD automates many steps from when code is developed to the point it is released in production. Similarly, Kubernetes automates container deployments across various infrastructure environments and ensures efficient resource utilisation.


1 Answers

The method of getting deployment feedback depends on your service and your choice. For example, you can check if the container is up or check one of the rest URL.

I use this stage as a final stage to check the service:

 stage('feedback'){
        sleep(time:10,unit:"SECONDS")
        def get = new URL("192.168.1.1:8080/version").openConnection();
        def getRC = get.getResponseCode();
        println(getRC);
        if(getRC.equals(200)) {
            println(get.getInputStream().getText());
        }
        else{
            error("Service is not started yet.")  
        }
    }

Jenkins can notify users about failed tests(jobs) with sending email or json notify. read more: https://wiki.jenkins.io/display/JENKINS/Email-ext+plugin
https://wiki.jenkins.io/display/JENKINS/Notification+Plugin
https://wiki.jenkins.io/display/JENKINS/Slack+Plugin

If you want continuous monitoring for the deployed product, you need monitoring tools which are different from Jenkins.

This is a sample picture for some popular tools of each part of DevOps: enter image description here

like image 99
M-Razavi Avatar answered Sep 16 '22 20:09

M-Razavi