A CentOS image straight off the marketplace shelf
boots with the instance key loaded into authorized_keys
for root
. We prefer ec2-user
. This new
/etc/rc.d/rc.local
helps, along with the pre-image procedure in ready.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
package = "luasnmp" | |
version = "1.0.6-2" | |
source = { | |
url = "https://github.com/hleuwer/luasnmp/archive/1.0.6-2.zip", | |
dir = "luasnmp-1.0.6-2" | |
} | |
description = { | |
summary = "LuaSNMP is a binding to the netsnmp library.", |
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/sh | |
# Build meld3 and supervisor wheels on CentOS | |
# Ship wheels/*.whl | |
# | |
# Installation doc then becomes: | |
# | |
# yum install -y epel-release | |
# yum install -y --enablerepo=epel python-pip | |
# pip install meld*.whl supervisor*.whl | |
# |
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
[ec2-user@hostname tmp]$ sudo rm -rf node_modules/ | |
[ec2-user@hostname tmp]$ npm install sleep | |
/ | |
> [email protected] install /tmp/node_modules/sleep | |
> node-gyp rebuild | |
gyp WARN install got an error, rolling back install | |
gyp ERR! configure error | |
gyp ERR! stack Error: incorrect header check | |
gyp ERR! stack at Zlib._binding.onerror (zlib.js:295:17) |
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
wait4eth1() { | |
CNT=0 | |
until ip a show eth1 | grep -q UP | |
do | |
[ $((CNT++)) -gt 60 ] && break || sleep 1 | |
done | |
sleep 1 | |
} | |
wait4eth1 |
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 | |
set -e | |
ROOT=/etc/pki/CA | |
ROOTKEY=$ROOT/private/ca.key.pem | |
ROOTCNF=$ROOT/openssl.cnf | |
ROOTCERT=$ROOT/certs/ca.cert.pem | |
ROOTDAYS=3650 | |
INT=$ROOT/intermediate | |
INTKEY=$INT/private/intermediate.key.pem |
First:
docker pull ubuntu:trusty # for fresh copy
docker run -t -i ubuntu:trusty
Then, in, the container:
export ARCHIVE=archive.ubuntu.com
export ARCHIVE=mirror.internode.on.net/pub/ubuntu
cat > /etc/apt/sources.list <
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/env node | |
// usage: | |
// blat.js & | |
// logstash agent -f inhale-all-seen.conf & | |
'use strict'; | |
var fs = require('fs'), | |
redis = require('redis'), |
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
'use strict'; | |
var autoprefixer = require('autoprefixer'); | |
module.exports = function autoprefix(BasePlugin) { | |
return BasePlugin.extend({ | |
name: 'autoprefix', | |
config: { | |
// fed straight to autoprefixer |
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
# logstash-forwarder debian build container | |
# | |
# usage: | |
# | |
# * copy this file into your logstash-forwarder checkout directory, then: | |
# * docker build -rm -t=lsfbuild . | |
# * docker run -rm -in lsfbuild ./tarout | tar xvf - | |
# | |
# result: logstash-forwarder_*.deb et al in your checkout directory without | |
# needing to have Ruby, GCC, or Go installed. |