See how a minor change to your commit message style can make you a better programmer.
Format: <type>(<scope>): <subject>
<scope>
is optional
cd ~ | |
wget http://mmonit.com/monit/dist/binary/5.12/monit-5.12-linux-x64.tar.gz | |
tar zxf monit-5.12-linux-x64.tar.gz | |
cd monit-5.12/ | |
cp bin/monit /usr/bin/ | |
mkdir /etc/monit | |
touch /etc/monit/monitrc | |
chmod 0700 /etc/monit/monitrc | |
ln -s /etc/monit/monitrc /etc/monitrc | |
wget https://gist.githubusercontent.com/gaurish/964456aa08c9fa2e43ee/raw/1aa107e62ecaaa2dacfdb61a12f13efb6f15005b/monit -P /etc/init.d/ |
# -*- coding: utf-8 -*- | |
'''Dump MongoDB databases to the zip archives | |
and copy its to the output folder. | |
Usage: python mongozip.py | |
''' | |
import os | |
import os.path | |
import datetime | |
import tempfile | |
import shutil |
'use strict'; | |
/** | |
* Module dependencies. | |
*/ | |
var mongoose = require('mongoose'), | |
AWS = require('aws-sdk'), | |
exec = require('child_process').exec, | |
fs = require('fs'), | |
name = new Date().toISOString(); |
storage: | |
dbPath: "/data/db/300-mm" | |
directoryPerDB: true | |
journal: | |
enabled: true | |
systemLog: | |
destination: file | |
path: "/data/db/300-mm/mongodb.log" | |
logAppend: true | |
timeStampFormat: iso8601-utc |
require("express-namespace"); | |
var express = require("express"), | |
fs = require("fs"), | |
cons = require("consolidate"), | |
app = express(), | |
passport = require("passport"), | |
mongoose = require("mongoose"); | |
// 30 days for session cookie lifetime | |
var SESSION_COOKIE_LIFETIME = 1000 * 60 * 60 * 24 * 30; |
#!/usr/bin/env bash | |
# names of latest versions of each package | |
export VERSION_PCRE=pcre-8.38 | |
export VERSION_OPENSSL=openssl-1.0.2d | |
export VERSION_NGINX=nginx-1.9.7 | |
# URLs to the source directories | |
export SOURCE_OPENSSL=https://www.openssl.org/source/ | |
export SOURCE_PCRE=ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/ |
map $http_origin $allow_origin { | |
default ""; | |
"~^https?://(?:[^/]*\.)?(stevebuzonas\.(?:com|local))(?::[0-9]+)?$" "$http_origin"; | |
} | |
map $request_method $cors_method { | |
default "allowed"; | |
"OPTIONS" "preflight"; | |
} |
PATH=/bin:/usr/local/bin | |
# Put this in your crontab file to run the script every day at 01:30 (1:30am). Note the PATH variable above; required for this script. | |
# m h dom mon dow command | |
30 01 * * * /bin/bash /home/ubuntu/scripts/ec2-create-image.sh i-8a915682 >> /home/ubuntu/logs/crontab.log 2>&1 |