Deep dive into AWS for developers | Part1 — IAM & EC2

  • IAM has a global-view and its applicable for all the regions.
  • Permissions are governed by policies. IAM also provides pre-defined managed policies.
  • It’s in best interest that, Users should be given minimal permissions that they need to perform their jobs. (Least Privilege Principle).
  • IAM credentials should never be shared and most-importantly, IAM credentials should never be written into the code.
  • First we update all our libraries at the EC2 instance :-
  • Next, we install the ‘httpd’ server :-
  • Next, we start the web-server :-
  • Next, we make sure that, service keeps running, even across instance-restarts.
  • Next, let’s write some static content to the file, that web-server shall be returning upon being invoked.
  • Now, if we want to access this web-server through web-browser, then it would not be allowed to happen, because our security-group only allows the inbound traffic on port 22 at this instance. So, let’s go ahead and allow the http based traffic on port no. 22 as well by modifying the security-groups as below :-




Software Engineer for Big Data distributed systems

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Simple Golang API Uploader Using Google Cloud Storage

Go Packaging

Building a music recognization app in SwiftUI with ShazamKit

Emergencies in Distributed Systems

The First One

Basic linux commands

Django Model Definitions: How They Differ From the Generated Database Schema

Show Promo

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
aditya goel

aditya goel

Software Engineer for Big Data distributed systems

More from Medium

Create High Availability Architecture Using AWS Command Line

AWS access keys IP filtering protection

Deploying Spring Boot application on AWS ECS

Task 5: How to configure EC2, EBS, and S3 in AWS using AWS CLI