Skip to content

Instantly share code, notes, and snippets.

View leetrout's full-sized avatar
🎸

Lee Trout leetrout

🎸
View GitHub Profile
@leetrout
leetrout / list-of-example-arns.js
Created November 11, 2025 22:25 — forked from cmawhorter/list-of-example-arns.js
list of all the example arns from the aws arns and namespaces doc page
// all the example arns from this page: http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html
var arns = [
'arn:aws:elasticbeanstalk:us-east-1:123456789012:environment/My App/MyEnvironment',
'arn:aws:iam::123456789012:user/David',
'arn:aws:rds:eu-west-1:123456789012:db:mysql-db',
'arn:aws:s3:::my_corporate_bucket/exampleobject.png',
'arn:aws:artifact:::report-package/Certifications and Attestations/SOC/*',
'arn:aws:artifact:::report-package/Certifications and Attestations/ISO/*',
'arn:aws:artifact:::report-package/Certifications and Attestations/PCI/*',
'arn:aws:autoscaling:us-east-1:123456789012:scalingPolicy:c7a27f55-d35e-4153-b044-8ca9155fc467:autoScalingGroupName/my-test-asg1:policyName/my-scaleout-policy',
@leetrout
leetrout / latency.markdown
Created June 10, 2025 14:27 — forked from hellerbarde/latency.markdown
Latency numbers every programmer should know

Latency numbers every programmer should know

L1 cache reference ......................... 0.5 ns
Branch mispredict ............................ 5 ns
L2 cache reference ........................... 7 ns
Mutex lock/unlock ........................... 25 ns
Main memory reference ...................... 100 ns             
Compress 1K bytes with Zippy ............. 3,000 ns  =   3 µs
Send 2K bytes over 1 Gbps network ....... 20,000 ns  =  20 µs
SSD random read ........................ 150,000 ns  = 150 µs

Read 1 MB sequentially from memory ..... 250,000 ns = 250 µs

@leetrout
leetrout / pxe-boot.md
Created July 7, 2024 17:28 — forked from Rafisto/pxe-boot.md
pxe-boot

How to easily setup PXE boot for cluster provisioning

This guide will show you how to setup a PXE boot server to provision a cluster of machines. For the sake of this guide, we will be using system agnostic docker containers to simulate the DHCP and the PXE boot server.

Featured technologies:

PXE boot description

@leetrout
leetrout / pxe-boot.sh
Created July 7, 2024 17:25 — forked from spipm/pxe-boot.sh
Create (UEFI/Secureboot) PXE boot server on interface
#!/bin/bash
# Run PXE boot server on interface
# Seems to work with UEFI and Secureboot
# Spip, 2023
#
# Most stuff from https://www.youtube.com/watch?v=E_OlsA1hF4k
#
# Check args
@leetrout
leetrout / all-the-way-downify.sh
Created April 20, 2023 17:41 — forked from lafentres/all-the-way-downify.sh
:*-all-the-way-down: Slack emoji creator, based off alisdair/intensify.sh
#!/bin/bash
# Credit to https://gist.github.com/alisdair/ffc7c884ee36ac132131f37e3803a1fe for the excellent original
# script that this one is based on. This script modifies the original to create the all-the-way-down effect.
# Generate a `:*-all-the-way-down:` Slack emoji, given a reasonable image
# input. I recommend grabbing an emoji from https://emojipedia.org/
set -euo pipefail
@leetrout
leetrout / jumboify.sh
Created April 20, 2023 17:41 — forked from lafentres/jumboify.sh
Jumbo Slack emoji creator, based off alisdair/intensify.sh
#!/bin/bash
# Credit to https://gist.github.com/alisdair/ffc7c884ee36ac132131f37e3803a1fe for the excellent original
# script that this one is based on. This script modifies the original to create the jumbo.
# Generate a jumbo Slack emoji, given a reasonable image
# input. I recommend grabbing an emoji from https://emojipedia.org/
set -euo pipefail
@leetrout
leetrout / partyify.sh
Created July 15, 2022 12:49 — forked from lafentres/partyify.sh
:something-party: Slack emoji creator, based off alisdair/intensify.sh
#!/bin/bash
# Generate a `:something-party:` Slack emoji, given a reasonable image
# input. I recommend grabbing an emoji from https://emojipedia.org/
set -euo pipefail
if [ $# -eq 0 ]; then
echo "Usage: $0 input.png"
exit 1
@leetrout
leetrout / since2010.md
Created March 3, 2022 16:18 — forked from shawwn/since2010.md
"What happened after 2010?"

This was a response to a Hacker News comment asking me what I've been up to since 2010. I'm posting it here since HN rejects it with "that comment is too long." I suppose that's fair, since this ended up being something of an autobiography.

--

What happened after 2010?

@leetrout
leetrout / README.md
Created August 23, 2019 21:45
Emulating a RasPi Utilizing QEMU