Skip to content

Instantly share code, notes, and snippets.

Eli Young elyscape

Block or report user

Report or block elyscape

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
elyscape / update-docker-completions.bash
Last active Mar 22, 2018
Script to add/update completion scripts from Docker for Mac. Assumes that bash-completion or bash-completion@2 in installed with Homebrew
View update-docker-completions.bash
#!/usr/bin/env bash
update-docker-completions() {
local prefix suffix srcdir='/Applications/'
# bash
for compl in "$srcdir"/*.bash-completion; do
ln -sf "$compl" "${prefix}$(basename "${compl%.*-completion}")${suffix}"
elyscape / heartbeat.conf
Last active Jul 18, 2019
Systemd configuration for heartbeat
View heartbeat.conf
elyscape / local-image
Last active Aug 14, 2017
Bash script to allow you to use `FROM image` in Dockerfiles even when using a private registry
View local-image
#!/usr/bin/env bash
readonly _skip_examples="local-image-skip-examples"
usage() {
local scriptname
scriptname="$(basename "$0")"
cat <<-EOF
Usage: ${scriptname} command
elyscape / random-hex.rb
Created Dec 15, 2016
Random generators
View random-hex.rb
#!/usr/bin/env ruby
require 'securerandom'
print 'Enter desired length of random hex string: '
length = gets
actual_length = Integer(length)
elyscape / Dockerfile
Last active Jan 18, 2017
These commands add dumb-init to a Docker image -
View Dockerfile
DUMB_INIT_SHA256SUM=81231da1cd074fdc81af62789fead8641ef3f24b6b07366a1c34e5b059faf363 && \
curl -fsSLo /sbin/dumb-init "${DUMB_INIT_VERSION}/dumb-init_${DUMB_INIT_VERSION}_amd64" && \
echo "${DUMB_INIT_SHA256SUM} */sbin/dumb-init" | sha256sum -c - && \
chmod +x /sbin/dumb-init
ENTRYPOINT [ "/sbin/dumb-init", "--" ]
elyscape / Dockerfile
Last active May 17, 2017
These commands add Tini to a Docker image -
View Dockerfile
# Set TINI_ARCH to one of:
# ''
# amd64
# arm64
# armhf
# i386
# static
# static-amd64
# static-arm64
# static-armhf
elyscape / ses-credential-generator.rb
Last active Jun 21, 2016
This script converts an AWS secret access key into an SMTP password for SES.
View ses-credential-generator.rb
#!/usr/bin/env ruby
require 'openssl'
require 'base64'
require 'io/console'
VERSION = "\x02".force_encoding('BINARY').freeze
MESSAGE = 'SendRawEmail'.freeze
digest ='sha256')

Keybase proof

I hereby claim:

  • I am elyscape on github.
  • I am elyscape ( on keybase.
  • I have a public key ASAmHBIJKn9FV4J09TR4dusU8wQhlc7SPZYJ-lQ75bGmEwo

To claim this, I am signing this object:

elyscape / caway.scpt
Created Jun 1, 2015
Away for the current server
View caway.scpt
on textualcmd(inputString, destinationChannel)
return "/quote AWAY " & inputString
end textualcmd
elyscape / remove_after.rb
Created May 28, 2015
View remove_after.rb
Puppet::Type.newtype(:remove_after) do
@doc = "Removes ensurable temporary resources once they have been used.
newparam(:temp_resource) do
desc <<-'EOT'
The ensurable resource to remove. This can be specified as either a
resource reference or as a string in the form "Type[name]". Note that
You can’t perform that action at this time.