<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Uday Reddy on Medium]]></title>
        <description><![CDATA[Stories by Uday Reddy on Medium]]></description>
        <link>https://medium.com/@udayreddym?source=rss-38406c392125------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*Udb0bYCguxqJv25tw5qP_w.jpeg</url>
            <title>Stories by Uday Reddy on Medium</title>
            <link>https://medium.com/@udayreddym?source=rss-38406c392125------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 25 Nov 2026 00:58:09 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@udayreddym/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[AWS CodePipeline for SAM]]></title>
            <link>https://udayreddym.medium.com/aws-codepipeline-for-sam-c50a29dfccff?source=rss-38406c392125------2</link>
            <guid isPermaLink="false">https://medium.com/p/c50a29dfccff</guid>
            <dc:creator><![CDATA[Uday Reddy]]></dc:creator>
            <pubDate>Thu, 25 Feb 2021 05:58:55 GMT</pubDate>
            <atom:updated>2021-02-25T06:21:17.411Z</atom:updated>
            <content:encoded><![CDATA[<h3>AWS CodePipeline for Serverless</h3><p>Today we are going to discuss how to set up AWS serverless applications from end to end. I have gone through many articles and felt like sharing the knowledge I have gained during this process. It is essential for one to automate these kinds of tasks, as we may need to create many pipelines for different applications, which can save time from redoing the same stuff. We are going to take a sample hello-world application and create a code pipeline using Terraform.</p><p><strong>Sample Application</strong></p><blockquote>Prerequisites</blockquote><p>i) AWS CLI (<a href="https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html">https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html</a>)</p><p>ii) AWS SAM CLI (<a href="https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/serverless-sam-cli-install.html">https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/serverless-sam-cli-install.html</a>)</p><p>iii) Python3 (<a href="https://www.python.org/downloads/">https://www.python.org/downloads/</a>)</p><p>iv) Terraform (<a href="https://www.terraform.io/downloads.html">https://www.terraform.io/downloads.html</a>)</p><blockquote>Github Code</blockquote><p>Please pull the code from the following GitHub repository and run the necessary commands as mentioned in the Readme.MD file.</p><p>git repo: <a href="https://github.com/udayreddy29/sam-app">https://github.com/udayreddy29/sam-app</a></p><p>The project structure looks like below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jYOAHAY6l_jkY2cUBlTmAA.png" /><figcaption>Fig 1 Sam project structure</figcaption></figure><p>Let us understand how to build this application. Initially, get into the folder where template.yml exists and run the below build command.</p><p><strong><em>sam build</em></strong></p><p>Whenever we make changes in the yaml files, we need to build the application. The sam build command builds the entire applications and it’s dependencies, copies the entire application source code to folders under .<strong>aws-sam/build </strong>folder.</p><p>The folder structure inside the <strong>.aws-sam</strong> folder:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*M3CKSjkvmLdLVFSkJ7GsBg.png" /><figcaption>Fig 2 build folder structure</figcaption></figure><p>Now, it’s time to set up application on AWS. We have to run the below command in order to deploy application on AWS.</p><p><strong><em>sam deploy -g</em></strong></p><p>Follow the on-screen prompts and copy the details you have enter on the command line. Please copy the details mentioned in the below picture.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ANN-zf_2NVMcOrf8seXdGA.png" /><figcaption>Fig 3 cloud formation stack details</figcaption></figure><p>This command deploys code in the AWS. It copies the build artifacts under .aws-sam folder to Amazon S3 which was created during above command and deploys the application using Amazon Cloud Formation. Cloud Formation is responsible for creating Api Gateway and Lambda functions the application requires.</p><p>Once everything is done, please run below command to test if application is working fine.</p><pre><strong>curl </strong><em>https://&lt;restapiid&gt;.execute-api.us-east-1.amazonaws.com/Prod/hello/</em></pre><p>After successfully deploying the application, you can see output like the following:</p><pre>{&quot;message&quot;: &quot;hello world&quot;}</pre><p>The above discussed steps are only responsible for deploying serverless application, but it is highly recommended to configure a CI/CD pipelines instead of doing it from the terminal.</p><p>We have successfully deployed application on AWS. Let’s use AWS CodePipeline to configure CI/CD pipeline for the sam application. Instead of manually creating an entire CI/CD pipelines, let’s use Terraform which is used to automate the task. Moving forward, if we want to create multiple CI/CD pipelines for different application, we can use this and create which would save so much of manual effort.</p><p>Please clone the below terraform code and run according to the steps mentioned in the Readme file.</p><blockquote>Terraform: <a href="https://github.com/udayreddy29/aws-codepipeline-sam.git">https://github.com/udayreddy29/aws-codepipeline-sam.git</a></blockquote><p>The above terraform code is responsible for creating code pipeline on AWS. Once the codepipeline is created, go to AWS dashboard and run it. After making the changes to the application(Sam-app), run the codepipeline. You can review the changes using the below URL.</p><pre><em>https://&lt;restapiid&gt;.execute-api.us-east-1.amazonaws.com/Prod/hello/</em></pre><p>UpComing Articles:</p><p>i) Canary and Blue Green Deployments for SAM Applications.</p><p>ii) Articles on Terraform(detailed explanation of tasks)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c50a29dfccff" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Micro Services with Docker]]></title>
            <link>https://udayreddym.medium.com/micro-services-with-docker-7ae2202c9165?source=rss-38406c392125------2</link>
            <guid isPermaLink="false">https://medium.com/p/7ae2202c9165</guid>
            <category><![CDATA[docker]]></category>
            <category><![CDATA[spring-boot]]></category>
            <category><![CDATA[devops]]></category>
            <category><![CDATA[microservices]]></category>
            <dc:creator><![CDATA[Uday Reddy]]></dc:creator>
            <pubDate>Sun, 09 Sep 2018 21:00:50 GMT</pubDate>
            <atom:updated>2018-09-10T02:47:03.149Z</atom:updated>
            <content:encoded><![CDATA[<p>In our previous discussion, we had enough discussion on <a href="https://medium.com/@udayreddym/containers-vs-virtual-machines-5ca1660a1440">Containers vs Virtual Machines.</a> So here I just want to talk more about containers and how they are used in the industry today. Previously, we used to run all our production servers on Ubuntu and have decided to move all our production set up to CentOs environment. It made us re-install all our dependencies again as we were doing it on different OS. It was very painful for us to download all dependencies once again manually. In order to overcome all these portability challenges, we have decided to use Docker.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/336/1*glD7bNJG3SlO0_xNmSGPcQ.png" /></figure><p>On top of base OS, we will have to install container engine like <strong>Docker</strong>. For entire setup, we just need to have a pre-configured file called Dockerfile which helps us to run each application as an isolated VM called <strong>containers</strong> on top of container engine(Docker). It helps us to run containers on any platform, there won’t be any additional manual things to work upon.</p><blockquote><strong><em>Encapsulate spring boot application in a Docker container</em></strong></blockquote><p>I’m currently working on the online video interview platform named, <a href="https://www.panna.ai/">Panna</a>. Since it is an end to end interview platform, it has different services. So we have decided to break down all our services into MicroServices in order to make it independent of other services for easy maintenance and scaling. Let me explain how we have encapsulated one of our components, <strong>Resume parser</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3z1C2PzWh5mlL3hTouE2Xw.png" /></figure><p>The above Dockerfile will tell docker how our image should be built. Let’s take a look at each command:</p><p><strong>FROM 235746/centos-java: </strong>This is a custom built docker image by me which consists of CentOs OS along with java on top of it.</p><p><strong>RUN mkdir /opt/resume-application: </strong>It<strong> </strong>creates a folder to copy the jar file inside it.</p><p><strong>COPY resume-snapshot-0.0.1.jar /opt/resume-application/: </strong>It copies the jar from the build directory to the specified path.</p><p><strong>WORKDIR /opt/resume-application/: </strong>It will change our current directory to the specified path.</p><p><strong>EXPOSE 9090: </strong>Here it tells Docker to expose the port 9090 when a container based on your image was started.</p><p><strong>ENTRYPOINT [ “sh”, “-c”, “java -Dspring.profiles.active=production resume-snapshot-0.0.1.jar” ]: </strong>It will start our application, whenever the container starts.</p><p>Once we write our Dockerfile, now it’s time to push it to DockerHub or any other docker registry. You can even have our own docker host registry. Since I use DockerHub, let me build and push our Dockerfile into it.</p><blockquote>docker build -t &lt;name&gt; .</blockquote><p>The above command is used to build our Dockerfile. Let’s create a tag and push it to docker registry.</p><blockquote>docker login</blockquote><blockquote>docker tag &lt;tag-name&gt; docker-id/repo:tagname</blockquote><blockquote>docker push docker-id/repo:tagname</blockquote><p>Now, this can be pulled anywhere and start running by exposing it to port 80 or 443.</p><blockquote>docker run -p 80:9090 docker-id/repo:tagname</blockquote><p>You can access your application by the IP of the server you are running this container. I hope this would help you build your own Dockerfile.</p><blockquote>http://hostname</blockquote><p><strong>Conclusion:</strong></p><p>Docker simplifies much of admin work and ensures the process is clean. It helps us to maintain different version of the software and easy to build and shipped to production.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7ae2202c9165" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What is DevOps?]]></title>
            <link>https://udayreddym.medium.com/what-is-devops-f642ee704012?source=rss-38406c392125------2</link>
            <guid isPermaLink="false">https://medium.com/p/f642ee704012</guid>
            <category><![CDATA[devops]]></category>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[cloud-computing]]></category>
            <category><![CDATA[process]]></category>
            <dc:creator><![CDATA[Uday Reddy]]></dc:creator>
            <pubDate>Sun, 09 Sep 2018 06:54:08 GMT</pubDate>
            <atom:updated>2018-09-09T18:41:31.565Z</atom:updated>
            <content:encoded><![CDATA[<p>DevOps is a buzzword which has been trending in the industry for quite some time now. Recently I have been to a conference DocOn which was held by a Tech company. The host who had come down to the conference has asked: “What is DevOps?”. Then, people started giving different opinions about DevOps. I have come across different definitions of DevOps and decided to put my own words about DevOps. I’m not here to debate but I just want to give my own theory of DevOps.</p><blockquote>I always believe that DevOps is a practice or process which results in improved software, delivered at a greater velocity. Let us understand what is DevOps with its life cycle.</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-NLvCHXpMJS8Bff7Tiuw8g.png" /><figcaption><strong>life cycle of DevOps</strong></figcaption></figure><blockquote><strong>The life cycle of DevOps</strong></blockquote><p><strong>Continuous Development</strong></p><p>In this phase, software is developed continuously. Unlike the waterfall model, all the deliverables are broken down into small sprints of shorter development cycles and then delivered in a short time. This stage involves coding and building phases which makes use of <strong>Git, Github</strong> etc for maintaining different versions of code and <strong>Maven, Gradle</strong> etc for building and packaging of code into an executable file.</p><p><strong>Continuous Testing</strong></p><p>In this phase, developed software is tested continuously. <strong>JUnit</strong> test cases will be useful to test the developed software during build phase itself. If the developed code fails to satisfy the JUnit test cases, build gets fail. They can also use <strong>Selenium</strong> which can be integrated further with DevOps tools used to test the software once the code is moved into the test environment.</p><p><strong>Continuous Integration</strong></p><p>Since there is continuous development of software, the updated code needs to be integrated continuously as well as smoothly with the systems to reflect changes to the end users. This need to be tested Continuously to make sure that it is working fine for end users. <strong>Jenkins</strong> will help us to achieve this for us. Whenever the developer pushes the changes, we can set a trigger on Jenkins to pull the code from Git, build the code and implement continuous testing.</p><p><strong>Continuous Deployment</strong></p><p>In this phase, the code is deployed to a production server. We have to ensure that code is deployed in the production server and it can handle enough traffic from end users. We have to come up with different scaling options to control the traffic. <strong>Puppet</strong>, <strong>Chef</strong>, <strong>SaltStack, </strong>and <strong>Ansible</strong> are some popular tools that are used in this stage. But recently <strong>Docker</strong> and <strong>Kubernetes</strong> are playing a crucial role in Continuous Deployment.</p><p><strong>Continuous Monitoring</strong></p><p>In the phases, we have to make sure that our application is up and running all the time. This practice involves the participation of the Operations team who will monitor the user activity for bugs / any improper behavior of the system. I use <strong>Zabbix</strong>, which helps us monitor the application and the servers closely to check the health of the system proactively. If some server goes down, it will send alerts and bring our applications back to a normal state.</p><p><strong>Conclusion</strong></p><p>I would define <strong>DevOps</strong> as a oneness between ‘Dev’ &amp; ‘Ops’ teams which results in improved software, delivered at a greater velocity. It is a process that ensures the proper implementation of Continuous Development, Continous Testing, Continuous Integration, Continuous Deployment, and Continuous Monitoring. We will be discussing in detail of each build cycle and the tools involved in our upcoming stories.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f642ee704012" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[CONTAINERS vs VIRTUAL MACHINES]]></title>
            <link>https://udayreddym.medium.com/containers-vs-virtual-machines-5ca1660a1440?source=rss-38406c392125------2</link>
            <guid isPermaLink="false">https://medium.com/p/5ca1660a1440</guid>
            <category><![CDATA[docker]]></category>
            <category><![CDATA[containers]]></category>
            <dc:creator><![CDATA[Uday Reddy]]></dc:creator>
            <pubDate>Tue, 28 Aug 2018 01:05:22 GMT</pubDate>
            <atom:updated>2018-08-28T03:56:39.867Z</atom:updated>
            <content:encoded><![CDATA[<p>Everyone is having different interpretation of VMs vs containers but the main intention behind writing this post is to explain what are containers and advantages of using it? Before you guys go and read this, I expect you have a basic idea of virtualization.</p><p>Before entering into this topic, Let’s go into Pre-Virtualization days. At that time, we used to buy very big physical servers and on top of it, we would install the desired operating system and run applications on it. This way each physical machine would run only one application at a time. This involves so many costs and would end up using very less amount of hardware resources.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*529Rz3hvC_mYqgeMwqKP2g.png" /></figure><p>From the concept of making use of full computing power and resources of a physical server, the concept called Hypervisor-based Virtualization came into the picture, where hypervisor layer is introduced on top of the operating system which allows us to install multiple virtual machines on top of the single physical server.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/535/1*UTZ3K5Yn4-8Fzs3Ht57t7Q.png" /></figure><p>This way, we can launch multiple VM’s on single physical servers and make use of them. Each VM would have it’s own operating system and use it’s own allocated compute and memory. This approach is very cost-effective and easy scaling.</p><blockquote><em>What is container and why it is used over virtual machine?</em></blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LL8jHPZY2dkIPkbWo-Z-ww.png" /></figure><p>We all know that In virtualization the operating systems (“OS”) and their applications share hardware resources from a single host server, or from a pool of host servers. Here each application is running in its own copy of kernel. But with containers, instead of virtualizing the underlying computer like a virtual machine (VM), just the OS is virtualized. Containers share host OS and this is much more efficient and light weighted.</p><blockquote><strong><em>Advantages:</em></strong></blockquote><p><strong>Runtime Isolation</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/697/1*ypHEooj0m_TwUrF8gAQ6jw.png" /></figure><p>For example, if we have to run two different applications with two different JREs on the same VM, container comes into the picture.</p><blockquote><em>We will anyways go into detail in our next coming blogs, but still let’s have a small introduction of implementing it. On top of base OS, we will have to install container engine like Docker. There would be different configuration files called Dockerfile for each application. Each application runs as a isolated VM called containers on top of container engine.</em></blockquote><p><strong>Portability</strong></p><p>We can run containers on any platform, there won’t be any additional manual things to work upon.</p><p><strong>Faster Deployments</strong></p><p>It facilitates faster software delivery.</p><blockquote><strong><em>Conclusion</em></strong></blockquote><p>I would like to conclude by saying that both containers and VMs are different ways of implementing virtualization(Software and Hardware). Instead of debating this vs that, I would prefer to say, using containers alongside with virtual machine will give us better results. We will talk more about it in my next blog.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5ca1660a1440" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to configure execution of scripts during server start-up & shutdown?]]></title>
            <link>https://udayreddym.medium.com/linux-runlevels-bede22de6694?source=rss-38406c392125------2</link>
            <guid isPermaLink="false">https://medium.com/p/bede22de6694</guid>
            <category><![CDATA[linux-kernel]]></category>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[linux]]></category>
            <category><![CDATA[linux-tutorial]]></category>
            <category><![CDATA[web-development]]></category>
            <dc:creator><![CDATA[Uday Reddy]]></dc:creator>
            <pubDate>Tue, 13 Feb 2018 17:07:45 GMT</pubDate>
            <atom:updated>2018-02-13T18:22:22.941Z</atom:updated>
            <content:encoded><![CDATA[<p>CentOs is configured in a such way that, it can boot into one of the run levels of different run levels available. During server start up, Init process looks into <strong>/etc/inittab</strong> file to check the default run level. Once it identifies the default run level, it executes all the scripts available in the <strong>/etc/rc.d/</strong> sub directory. The following are the available run levels in linux.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*f2zXh5ewk_U9_zpgxkuweQ.jpeg" /></figure><p>Let us understand how to execute scripts during system startup and shutdown:</p><p><strong>During system startup:</strong></p><p>At first, get the default run level of the shell since it varies from distributions. Place your script in <strong>/etc/init.d</strong> folder with executable permissions and create a symlink under <strong>/etc/rc{N}.d/</strong> sub-directory.</p><p><strong><em>ln -s /etc/init.d/scriptname /etc/rc{N}.d/S##scriptname</em></strong></p><p>Note: <strong><em>{N}</em></strong> indicates default runlevel value, in order get the runlevel value use the following command;</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/602/1*y9accItHljYjrf4hcvCipw.png" /></figure><p>Note:<strong><em> ##</em></strong> indicates a number that specifies the order of execution of script.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rPvF4v-XADKAORNFjYJOYg.png" /></figure><p><strong>During system shutdown:</strong></p><p>By default, the run level while system shutdown is 0. So, we need to create a script under <strong>/etc/init.d</strong> and give executable permission. Then, create a symlink under <strong>/etc/rc0.d/</strong> directory.</p><p><strong><em>ln -s /etc/init.d/scriptname /etc/rc0.d/K##scriptname</em></strong></p><p>Note: Use <strong><em>K00</em></strong> to execute your script at first while shutdown sends stop signal to script.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=bede22de6694" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>