Skip to content

Instantly share code, notes, and snippets.

==== {section}/{label}
{description} +
Required: {required} +
Description: Enable Debug Mode
Type: String
AllowedValues: [ "true", "false" ]
Default: "true"
isFalse: !Equals [ 'true', 'false' ]
isDebug: !Equals [ 'true', !Ref CfnDebug ]
rickalm /
Last active December 6, 2018 17:43
How to discover Docker Public ports with AWS ECS
# When wanting to search for port 7000 (example) you would query the ECS agent endpoint searching for your docker
# container by its ID ($HOSTNAME). You can then parse the resulting json yourself, or use JQ to find the HostPort
# curl -sS$HOSTNAME \
# | jq '.Containers[].Ports[] | select (.ContainerPort == 7000) | .HostPort'
# The following will create env vars identifying the public port numbers for mapped private ports
# (example assuming docker is exposing 80,443 and 8080)
# PUBLIC_PORT_80=32777
git name-rev --tags --name-only $(git rev-parse HEAD)
rickalm /
Last active April 15, 2016 17:36
Transform the /dev/xvd[b-z] devices on AWS to /dev/ephemeral[0-9]
# this script will attempt to detect any ephemeral drives and create /dev/ephemeral[0-9] device names
# Beware, This script is NOT fully idempotent.
# figure out the nameing convention