Category: Cloud Architecting

  • Where Is It 5 O’Clock Pt: 2

    So I spend the evening deploying this web application to Amazon Web Services. In my test environment, everything appeared to be working great because every time I reloaded the page it reloaded the function as well. When I transferred this over to a live environment I realized the Python function only ran every time I…

  • Where Is It Five O’Clock Pt: 1

    I bought the domain whereisitfiveoclock.net a while back and have been sitting on it for quite some time. I had an idea to make a web application that would tell you where it is five o’clock. Yes, this is a drinking website. I saw this project as a way to learn more Python skills, as…

  • EC2 Action Slack Notification

    I took a brief break from my Lambda function creation journey to go on vacation but, now i’m back! This function will notify a Slack channel of your choosing when an EC2 instance enters “Starting, Stopping, Stopped, or Shutting-Down” status. I thought this might be useful for instances that reside under a load balancer. It…

  • Check EC2 Instance Tags on Launch

    In my ever-growing quest to automate my AWS infrastructure deployments, I realized that just checking my tags wasn’t good enough. I should force myself to put tags in otherwise my instances won’t launch at all. I find this particularly useful because I utilize AWS Backup to do automated snapshots nightly of all of my instances.…

  • AWS Tag Checker

    I wrote this script this morning as I was creating a new web server. I realized that I had been forgetting to add my “Backup” tag to my instances so that they would automatically be backed up via AWS Backup. This one is pretty straight forward. Utilizing Boto3 this script will iterate over all of…

  • Lambda Function Post to Slack

    I wrote this script out of a need to practice my Python skills. The idea is that if a file gets uploaded to an S3 bucket then the function will trigger and a message with that file name will be posted to a Slack channel of your choosing. To utilize this you will need to…

  • Automatically Transcribing Audio Files with Amazon Web Services

    Automatically Transcribing Audio Files with Amazon Web Services

    I wrote this Lambda function to automatically transcribe audio files that are uploaded to an S3 bucket. This is written in Python3 and utilizes the Boto3 library. You will need to give your Lambda function permissions to access S3, Transcribe and CloudWatch. The script will create an AWS Transcribe job with the format: ‘filetranscription’+YYYYMMDD-HHMMSS I…

  • Monitoring Disk Space with CloudWatch

    I recently had a request to monitor disk space. Being that I don’t use a traditional monitoring platform but rather send all of my alerting to Slack I wondered how this would work. There is not a direct metric in CloudWatch so we will utilize the scripts available in this guide. You can follow along…

  • AWS CLI For CPU Credit Balance

    AWS CLI For CPU Credit Balance

    Here is how you create a CloudWatch alarm to monitor CPU Credit Balances less than a certain amount: aws cloudwatch put-metric-alarm –alarm-name YOUR NAME HERE–alarm-description “Alarm when CPU Credits is below 200” –metric-name CPUCreditBalance –namespace AWS/EC2 –statistic Average –period 300 –threshold 200 –comparison-operator LessThanThreshold –dimensions Name=InstanceId,Value=INSTANCEIDHERE –evaluation-periods 2 –alarm-actions ARN:YOURSNSTOPIC CloudFormation Template:https://github.com/avansledright/CloudFormation-CPU-CREDIT-BALANCE

  • Encrypt an Existing EBS Volume

    Encrypt an Existing EBS Volume

    Say you have an existing EBS volume on Amazon Web Services that you wanted to encrypt. How would you do that? The following guide shows you how to do so via the AWS Management Console. Login to your console. Navigate to the the EBS Volume you would like to encrypt 3. Right click on your…