Skip to content

Instantly share code, notes, and snippets.

@aaronfeng
aaronfeng / gist:8478425
Last active January 3, 2016 14:49
latest chef with omnibus
Bundler could not find compatible versions for gem "json":
In Gemfile:
chef (~> 11.8.2) ruby depends on
json (<= 1.7.7, >= 1.4.4) ruby
omnibus (~> 1.3.0) ruby depends on
json (1.8.1)
@aaronfeng
aaronfeng / gist:8698709
Created January 29, 2014 22:40
docker registry
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/gevent/greenlet.py", line 390, in run
result = self._run(*self.args, **self.kwargs)
File "/docker-registry/lib/storage/boto_base.py", line 48, in _fetch_part
boto_key.get_contents_to_file(f, headers={'Range': brange})
File "/usr/local/lib/python2.7/dist-packages/boto/s3/key.py", line 1578, in get_contents_to_file
response_headers=response_headers)
File "/usr/local/lib/python2.7/dist-packages/boto/s3/key.py", line 1418, in get_file
query_args=None)
File "/usr/local/lib/python2.7/dist-packages/boto/s3/key.py", line 1471, in _get_file_internal
package main
import (
"fmt"
"net"
"bufio"
"io"
"os"
"time"
)
@aaronfeng
aaronfeng / gist:9cfae309fd73f2e45942
Created June 18, 2014 14:04
libswarm aggregate
./swarmd "dockerserver tcp://localhost:4243" "aggregate 'ec2 --ami=xxxx --keypair=xxxx --tag=xxxx' 'dockerclient tcp://x.x.x.x:4243'"
@aaronfeng
aaronfeng / ec2-libswarm-readme.md
Last active December 6, 2015 10:00
README for libswarm EC2 Service

https://github.com/docker/libswarm

EC2 Libswarm Service

This service will deploy Docker container onto EC2 instance. It will do all of the work spinning up the instance if it doesn't exist already.

Usage:

export AWS_ACCESS_KEY_ID=XXXX

@aaronfeng
aaronfeng / cloud-init
Created October 7, 2014 18:15
cloud-init for Digital Ocean
#cloud-config
coreos:
etcd:
discovery: https://discovery.etcd.io/<token>
addr: $private_ipv4:4001
peer-addr: $private_ipv4:7001
fleet:
public-ip: $private_ipv4 # used for fleetctl ssh command
units:
@aaronfeng
aaronfeng / docker-machine.zsh
Created February 4, 2015 22:35
zsh helper to work with docker-machine
docker-machine-wrapper() {
CONFIG_NAME="$1"
shift
docker $(docker-machine config "$CONFIG_NAME") $@
}
alias dm="docker-machine-wrapper"
[user]
name = Aaron Feng
email = [email protected]
[diff]
tool = vimdiff
[color]
ui = auto
status = auto
@aaronfeng
aaronfeng / gist:d27c1099bba1821bb590
Last active August 29, 2015 14:18
heka docker base image log
[ 20%] Completed 'lua-5_1_5'
[ 20%] Built target lua-5_1_5
Makefile:147: recipe for target 'all' failed
make[3]: *** [all] Error 2
CMakeFiles/lua_sandbox.dir/build.make:110: recipe for target 'ep_base/Stamp/lua_sandbox/lua_sandbox-build' failed
make[2]: *** [ep_base/Stamp/lua_sandbox/lua_sandbox-build] Error 2
CMakeFiles/Makefile2:1707: recipe for target 'CMakeFiles/lua_sandbox.dir/all' failed
make[1]: *** [CMakeFiles/lua_sandbox.dir/all] Error 2
Makefile:147: recipe for target 'all' failed
make: *** [all] Error 2
@aaronfeng
aaronfeng / gist:9489158e8e06d751e1b1
Created March 30, 2015 23:18
heka es output checkpoint.txt
„I{"index":{"_index":"31559528a22df380c968a77866c9ba4fa30ded7a7bae0ae52a1c9ee34b266c80-2015.03.30","_type":"logfile-31559528a22d"}}
nil{"index":{"_index":"31559528a22df380c968a77866c9ba4fa30ded7a7bae0ae52a1c9ee34b266c80-2015.03.30","_type":"logfile-31559528a22d"}}
nil{"index":{"_index":"31559528a22df380c968a77866c9ba4fa30ded7a7bae0ae52a1c9ee34b266c80-2015.03.30","_type":"logfile-31559528a22d"}}
nil{"index":{"_index":"31559528a22df380c968a77866c9ba4fa30ded7a7bae0ae52a1c9ee34b266c80-2015.03.30","_type":"logfile-31559528a22d"}}
nil{"index":{"_index":"31559528a22df380c968a77866c9ba4fa30ded7a7bae0ae52a1c9ee34b266c80-2015.03.30","_type":"logfile-31559528a22d"}}