Understand best practices and continuous integration using Adobe Cloud Manager.
Hello everyone. My name is Varun Mitra and welcome to the video. In this particular lesson, we will talk about deploying code in a continuous integration pipeline. After completing this training, you will be able to deploy code in a continuous integration pipeline.
Now let us quickly go ahead and see how you can leverage production and non-production pipeline for doing a code deployment. I’m going to go back to my Cloud Manager Instance. Right over here you can see that I have brought up production and a staging environment and have a production and non-production pipelines. I can quickly go ahead and initiate a build over here.
Whenever I will take the build button, a quick validation will be done for the pipeline settings and the building unit testing phase will be started. Building unit testing leverages Maven framework for performing a Maven pen and running the test cases. An important part of your code base for AEM as a cloud service is that you need to write test cases for different Java classes that are there in your code base. Your test coverage should be 50%. In addition to this, your code will go through different code scaling steps. Your code should be compliant with the code scanning steps that are executed within the cloud manager. Once your code passes the code scanning, it will go through build image. And finally, once the image has been built, your code will be deployed to the staging environment. Where in a round of performance and security testing will be performed. Most that your code will be deployed onto the production environment. Now this particular pipeline is an actual and live pipeline. As such it will take some time to finish itself, as at least to execute all of these different checks. So, by using the production pipeline, you can make sure that your code is performing and always the good code is deployed on your production and it’s staging environment.
In addition to this, you have different non production pipelines. For example, this is my nonproduction pipeline. I can click on the edit button. This particular pipeline is a code quality pipeline. That is, it will run on my ticket branch and it will tell me whether my code is compliant with different cloud manager practices or different cloud manager checks or not. I can run this particular pipeline on different good projects. That is, I can have multiple code quality pipeline, which I can run on different Git projects just to verify if my code is performing or if it will pass through the cloud manager test or not. So, let me also quickly go ahead and run this code quality pipeline. Since this is not production pipeline. It will not perform a deployment on my live environment. It will just run a Maven build unit testing step and it will perform a code scan. Of course, that an image will be built. This image, however, will not be deployed onto the live environment. Once all of the system, I will get to know whether my code is performing or not. And if it can pass through cloud manager tests. So, using the code quality pipeline, your ingenious that is your developer, can know if the code that they’re writing is compliant with cloud manager framework or not. And if the code is performance and good enough to be deployed on a production staging or development environment. In addition to this, I can always change the pipeline settings by going to the edit button. I can specify the branch since the pipeline is running as such, I cannot make these changes. However, what’s the pipeline finishes execution. I can modify the kid branch. I can change environment settings and find that we also change the testing step that I want to be executed. I can specify a combination of different pages. Specify what kind of assets I want to have my code tested.
So, this is how you can set up your pipeline. Similarly, you can also configure or add new nonproduction pipeline, by clicking on this add button. You can have as many code quality pipelines as you want. However, you can have just one deployment pipeline, running within your cloud manager instance.
So, this is how you can set up the pipelines within your cloud managing instance. At any point, if you want to check the execution, you can either go to the activity tab and look at execution for different pipelines. You can also look up the execution for prior pipelines that have run. You can go to any other pipeline that was run and you can download the results for that particular pipeline. For example, this particular pipeline executed successfully and performed a production deployment. I can view the code scanning results, and I can verify if all the tests have passed or not. If any of the results were overwritten, I would have been able to know from here. I can also the production log. That is the deployment logs or the staging deployment log or the build image stage logs.
In addition to this, I can go to the pipeline card and I can verify if the pipeline execution was successful or not. I can also view the status for any running pipeline that might be executing at a particular point. So, this is how you can run a continuous integration and continuous deployment pipeline within cloud manager.
So now you should be able to deploy code in a continuous integration pipeline. Thank you very much for watching this video and have a great day. -