Skip to content

Instantly share code, notes, and snippets.

View imbriaco's full-sized avatar

Mark Imbriaco imbriaco

View GitHub Profile
#!/usr/bin/env sh
# each environment key/value pair should include the bundle name as follows:
# RELAYBUNDLE__name__KEY=VAL
for key in $(env | grep RELAYBUNDLE | sed -e 's/\(.*\)__\(.*\)__\(.*\)/\1:\2:\3/g'); do
BUNDLE_NAME=$(echo $key | cut -d: -f2)
BUNDLE_KEYVAL=$(echo $key | cut -d: -f3)
BUNDLE_KEY=$(echo ${BUNDLE_KEYVAL} | cut -d= -f1)
BUNDLE_VAL=$(echo ${BUNDLE_KEYVAL} | cut -d= -f2)
BUNDLE_PATH="/tmp/bundle_configs/${BUNDLE_NAME}"