Skip to main content

Posts

2021

Create Thumbnail Worker With S3 and Lambda: Test the Trigger

·7 mins
Introduction # In this post, we are going to see how we can use existing AWS infrastructure to create thumbnail for uploaded images. In this venture, we are going to use S3 trigger to execure Lambda function to do whatever we want. But in this case, we’ll create thumbnail so that we can save on some bandwidth when only a smaller version of image is required on the frontend.

Getting Started with Ansible as a Fullstack Developer

·18 mins
Introduction # I don’t claim to be a DevOps expert. I just know some basic ssh and scp, that’s all. I have done whatever server configuration till date by ssh’ing into instances and then configuring them by hand. But now-a-days I feel like spinning up and destroying a server has increased in my life style. And doing it manually is just waste of time when we already have solution like Ansible.

How to Spin Up Your Own VPN on Ubuntu 20.04

·8 mins
Introduction # There are a plenty of VPN providers out there. What’s common between all of them? You can’t trust them. They may have a no-log policy but as a company, there is always a tendency that they might share our browsing data to some third party. In this post you’ll learn how you can spin up your own VPN with Amazon AWS.

Port Forwarding and How to Do It With SSH

·2 mins
Introduction # Started with my Pentium 4 processor desktop with merely 256 MB of RAM. And today I’m port forwarding sitting on my laptop in a cloud enabled web. Today we’ll see how I have manage to make a tunnel between my laptop and EC2 instance that I own. In this short post, I will show how we can forward port from a remote host to a local computer. We will forward a port from AWS EC2 to local computer with openssl.

When User Data Scripts Are Not Enough, Create a New Image

·7 mins
Introduction # I have been using AWS with Terraform to provision my development instance on AWS cloud. When I wanted to configure dotfiles, change SSH port and configure some cron jobs, I hit a bottleneck. I literally was not able to do those tasks with user scripts because they had no effect. That was the time when creating custom image of the distro came into my mind.

Microservices and AWS

·6 mins
This is my rundown of AWS’s whitepaper about Implementing Microservices on AWS. Without further ado, let’s get started. In this article I talk more about micrsoservices and less about AWS. I also talk about paths already engraved around microservices. While you read this post, take a moment to connect with me on LinkedIn. What are microservices? # Microservices are an architectural and organizational approach to software development where software is composed of small independent services that communicate over well-defined APIs. These services are owned by small, self-contained teams.

Very Basics of Concurrency in Go

·7 mins
Introduction # I’ve dabbled over many languages in the past. Let it be PHP, Java, Python, C/C++, JavaScript and now Go (some of them I only know the syntax). With the experience of all the languages, when I switched to Go, I had no pain understand slices, struct, interfaces, relatively less pain understanding pointers (I’m still learning). But in non of those languages, I did concurrent programming. Although in my first company I did some concurrent programming using Python threads, but the threads didn’t share any data between them.

Git Submodules Basics and How to Replace One Submodule With Another

·7 mins
Introduction # Git Submodules are the concept related to modularity. One git repository can be added to another as a submodule and maintained separately. Instead of being tightly coupled, it is loosely coupled and is easy to maintain. Suppose you are working with softwareA which depends on libraryA, instead of copy-pasting the libraryA over and over again when a new version of the library is released what we can do is use submodule to make this process DRY and elegant.

How I Enabled HTTPS on My EC2 Hosted Website

·7 mins
Introduction # In 2014, Google hinted that they are running tests taking into account whether sites use secure, encrypted connections as a signal in our search ranking algorithms. This means it will affect SEO in some way. Today in the age of HTTP2, https is default. Default in the sense that many server software will only allow HTTP2 when https is configured.

Inheritence in JavaScript with Prototypes

·2 mins
Introduction # This is a short post about inheritence in JavaScript. While you read this post, take a moment to connect with me on LinkedIn. Body # Not until ECMAScript 2015 had class syntax. Before that there was prototype inheritance Suppose there is a function: 1 2 3 4 function FullName() { this.firstName = x; this.lastName = y; } Now when you want to return the fullname, you can either define a function inside the FullName function only, like this;

2020 in Review: Soft Skills, Books, Cloud and SE Practices

·10 mins
Introduction # Each year I post about what have I done in that particular year, inclining it more toward career. This is to document my process of learning over the year. I know I’m too late for a year in review post, but every time I wanted to post, there was something more high priority coming up. Today I have somehow managed to finish creating a featured image and make an end to the post.

2020

Beginner's Introduction to Promises in JavaScript

·2 mins
Introduction # Promise is a language feature for asynchronous programming in JavaScript. As JavaScript is single threaded, if you are doing something which waits for I/O, you create a Promise for that task. This task could be waiting for an API call from Twitter for example, or reading a file from a filesystem), and you let it run without getting in the way of normal execution flow.

Data Structures 101

·8 mins
Introduction # Like most self-taught programmers, I spent a lot of my years dabbling with different technologies. But there comes a time in every programmer’s life when they have to learn data structures and algorithms to proceed in their careers. In this post, I will go through the basics of data structures, what purpose they serve, and what’s common between all of them.