DevOps on AWS: Everything You Need to Know

DevOps is renowned for fast methodologies, increased security (in the form of DevSecOps), as well as the quick and easy scalability of software development projects. These advantages make it essential for companies to embrace the DevOps culture as a guarantee of future success and growth. 

At the heart of this change, we have Amazon and its pioneering cloud offering, Amazon Web Services. Being the most popular in the market means Amazon has some of the best services, infrastructure, locations, and support in the market. The amount of trained professionals in AWS DevOps is also the highest among the big three; Google Cloud Platform, Microsoft Azure, and AWS.

Adding a Custom Domain and SSL to AWS EC2

In our previous article, we Dockerized our Node.js server, pushed that container image to AWS ECR, and then launched an EC2 instance with that container running inside. With our network and security group configured, we could send HTTP requests to our EC2 instance (at port 80) and receive responses from our server.

For our next trick, let's set up a custom domain name and make our server accessible via HTTPS. Here are the steps we're going to take:

Spring Boot Pet Clinic App: A Performance Study

Spring pet clinic application is a sample application developed by the Spring Framework developers to demonstrate the capabilities of Spring Boot, Spring MVC, and Spring Data Framework. We set out to conduct a performance test on this application and see whether we can identify any performance bottlenecks.

Environment Setup

We cloned the Spring pet clinic application’s official Github repository and followed instructions to build a JAR file. Once the JAR file was ready, we launched the application on http://localhost:8080.

How to Create an AWS ALB and ASG

In this post, you will learn how to create an AWS Application Load Balancer (ALB) for your EC2 instances running a Spring Boot application. You will also create an Autoscaling Group (ASG) which will simplify the setup and will automatically scale-in and scale-out.

1. Introduction

A load balancer will make it possible to distribute the workload across multiple EC2 instances. A client application will connect to the load balancer without knowing which EC2 instance will handle the request. Because of this, EC2 instances can come and go without impacting your client requests. It is transparent because of the load balancer. It is easy to scale-out and thus to add more EC2 instances when traffic increases, or to scale-in and reduce the number of EC2 instances in order to reduce costs when traffic gets low.

How to Create an AWS EC2 VM

In this post, you will learn how easy it is to create a virtual machine with AWS EC2. You will learn the basics and as an example, you will deploy and run a basic Spring Boot application. Enjoy!

1. Introduction

Amazon EC2 (Elastic Compute Cloud) is one of the most popular AWS services. It allows you to create cloud computing instances in no time. You have the choice out of predefined templates (AMI) for several Operating Systems. Pricing is dependent on what kind of purpose the instance needs to serve. Whether you want to have an instance continuously running, or only at a scheduled interval, or you need bare metal, or a dedicated instance, etc. Many options are available for different purposes. Besides that, a lot of different configurations are available to choose from. You will need to choose the right one for your application. In the Free Tier, you only use the micro instance. All of this information is available at the Amazon website and therefore only links to these pages are provided. The offerings may change and you should refer to the Amazon website for the details.

Quickly Find Your Java Application Process ID

In this post, we are going to discuss how to find your Java application process ID quickly. For certain monitoring tools like yCrash, you need to pass your application process ID as input.

Finding Java Application Process ID in Linux

 On any Linux/Unix flavor of operating system, issue the command:

Implementing HTTP Load Balancer Using HAProxy on AWS

Overview

HAProxy (High Availability Proxy) is an open source, fast, and reliable solution that provides load balancer and reverse proxy features for TCP- and HTTP-based applications. HAProxy load balancer handles heavy load traffic and reroutes requests seamlessly across multiple servers. 

HAProxy also supports the following features:

Learn How to Deploy a Django Application

In this post, we'll go over the steps to deploy a Django application on a production server. I am using an AWS ec2 server, an Ubuntu 20.04 instance, and Python 3.8. The steps are the same for most versions of Ubuntu and Python, however, the syntax might differ based on the version you are using.

Steps

  1. Install Apache2.
  2. List out the project's folder and file's path.
  3. Collect static files.
  4. Migrate the database.
  5. Change the permission and ownership of the database files and other folders.
  6. Make changes in the Apache config file.
  7. Enable the site.
  8. Install WSGI mod in Apache2.
  9. Restart the Apache Server.

Step 1: Install Apache 2

 The following are the commands to install the Apache 2 server on the Ubuntu instance.

EC2 Scheduling Best Practices

Save money and optimize costs with EC2 scheduling.

The "pay for what you consume" model has been favored by AWS users for as long as one can remember. Even with EC2 instances, there are certain servers that need to be kept running 24/7, usually in the production environment; but other servers in the staging and dev environments are only used at certain calculable intervals. So running all your instances at all times prohibits you from leveraging the best part of AWS. This is where basic instance scheduling comes in, where you automate the start and stop of such non-essential instances according to a schedule.

You may also enjoy:  Provision a Free AWS EC2 Instance in 5 Minutes

EC2 instance scheduling in itself has become a best practice for optimizing instance usage and costs; but we’ve realized that the process of scheduling can also intrinsically be optimized, with certain best practices to define it. The savings that you generate just through basic scheduling during regular business hours can run up to almost 70%, imagine what happens if you go a step further. Here are some best practices to follow when it comes to scheduling your instances.