Skip to content

Instantly share code, notes, and snippets.

View bryanherger's full-sized avatar

bryanherger

  • New York, NY
View GitHub Profile

Keybase proof

I hereby claim:

  • I am bryanherger on github.
  • I am bryanherger (https://keybase.io/bryanherger) on keybase.
  • I have a public key ASBPFeMlrp2mBGpNyZFKr1uhpF-7tUA1z2xdoziV-tBJJAo

To claim this, I am signing this object:

@bryanherger
bryanherger / gp3.sh
Created January 13, 2021 00:41
Convert AWS EBS volumes in a region to gp3
# you can save a bit of money and sometimes get better performance by upgrading older volume types to gp3.
# this script can update all volumes in a region; it's a "hot" upgrade so can be done on all.
# though you may wish to set a filter: in this examples, only update gp2 types are touched (--filter Name=volume-type,Values=gp2)
# this script takes one optional argument: region (default us-east-1)
# be sure to run "aws configure" and set a key pair or set an IAM role that can modify EBS volumes
#!/bin/bash
r=${1:-us-east-1}
for v in $(aws ec2 describe-volumes --query 'Volumes[*].[VolumeId]' --region $r --output text --filter Name=volume-type,Values=gp2)
do
echo $v
@bryanherger
bryanherger / README.md
Created February 1, 2019 16:45 — forked from fasiha/README.md
Set up RTL-SDR, dump1090, and dump978 for ADS-B/TIS-B/FIS-B/UAT on macOS

Introduction

I’m not very familiar with the aviation jargon (see FAA’s ADS-B FAQ), but ADS-B is a next-gen system where aircraft are equipped with transponders that periodically broadcast their own positions and receive the reports from both other aircraft (direct air-to-air) as well as air-traffic control (ATC) ground transmitters.

There are two separate ADS-B radio bands: the commercial aviation (CA) is at 1090 MHz while the general aviation (GA) is at 978 MHz. If I can be permitted a gross generalization—the former corresponds to big commercial jets and the latter to small private aircraft.

Because ADS-B is designed to democratize airspace situational awareness (in contrast to the older setup, like from films, where a central air-traffic controller is coordinating all these aircraft that can’t see each other), we can buy cheap RF receivers to pick up and decode the messages being broadcast by aircraft and ground towers to get our own picture of the

@bryanherger
bryanherger / hod_sentiment.lua
Created August 27, 2016 17:37
Lua CFS script to retrieve sentiment analysis from Haven OnDemand and store in an IDOL document field.
local function isempty(s)
return s == nil or s == ''
end
function handler(document)
local config = get_config("cfs.cfg")
local log = get_log(config, "IndexLogStream")
log:write_line( log_level_error() , "HOD started")
local sentText = document:getFieldValue("DRECONTENT")