This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
defmodule DieCloudfilesDie.Devil.Minion do | |
use GenServer | |
@name __MODULE__ | |
def start_link(container, agent_pid, marker_pid, parent_pid) do | |
{:ok, pid} = GenServer.start_link(__MODULE__, [container, agent_pid, marker_pid, parent_pid], name: @name) | |
end | |
def init(container, agent_pid, marker_pid, parent_pid) do | |
# Retrieve Marker |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### ./script/do_my_build.sh | |
source ./script/source_me.sh | |
echo "output a lot of lines" | |
for i in {1..100}; do | |
echo $i | |
done | |
### ./script/source_me.sh |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
defmodule DogStatsdSupervisor do | |
use Supervisor | |
def start_link do | |
Supervisor.start_link(__MODULE__, :ok) | |
end | |
def init(:ok) do | |
children = [ | |
worker(DogStatsd, [%{host: "localhost", port: 8125}, [name: DogStatsd]]), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#set($inputRoot = $input.path('$')) | |
{ | |
"httpMethod": "$context.httpMethod", | |
"input": "$util.escapeJavaScript($input.body)" | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash -e | |
# There's an assumption we're two directories into the repo (scripts/buildkite) | |
basedir=$(dirname $0) | |
pushd ${basedir}/../../ | |
image_tag=$1 | |
cache_sha_sum=$2 | |
if [[ -z $image_tag || -z $cache_sha_sum ]]; then |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GPG_ENV=$( gpg-agent --daemon 2>/dev/null ) | |
if [ $? == 0 ]; then | |
eval $GPG_ENV | |
else | |
export SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket) | |
fi | |
export GPG_TTY=$(tty) | |
function copy-code() { | |
echo $1 |sed -e 's/[^ ]* //' |pbcopy |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
INIT='eval $(docker-machine env docker5)' | |
PARSE = 'echo parse_url("http://google.com#@example.com/", PHP_URL_HOST);' | |
READ = 'echo readfile("http://google.com#@example.com/");' | |
versions = [] | |
14.upto 25 do |i| | |
versions << "7.0.#{i}" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
# -*- coding: utf-8 -*- | |
############################################################################## | |
# Copyright 2017 Amazon.com, Inc. or its affiliates. All Rights Reserved. # | |
# # | |
# Licensed under the Amazon Software License (the 'License'). You may not # | |
# use this file except in compliance with the License. A copy of the # | |
# License is located at # | |
# # |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* eslint-env es6 */ | |
'use strict'; | |
var assert = require('assert'); | |
let harness = (req, res, callback, next) => { | |
try { | |
assert.equal(typeof callback, 'function'); | |
} catch (E) { | |
return callback(E); | |
} | |
try { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function aws-code() { | |
ykman oath -s bastion-account | |
} | |
function aws-vault-exec() { | |
local role_name=$1 | |
export AWS_ACCOUNT=$role_name | |
shift | |
local command=$@ | |
local extra_args="" |