Skip to content

Instantly share code, notes, and snippets.

View christianhellsten's full-sized avatar
🛰️
In space

Christian Hellsten christianhellsten

🛰️
In space
  • https://aktagon.com
  • 05h 38m 38s, −69° 5.7′ 0″, 160 ± 10 k ly (In space)
View GitHub Profile
# Q sample by Jeff Cogswell
#===========
# We want to call these three functions in sequence, one after the other:
#
# First we want to call one, which initiates an ajax call. Once that ajax call
# is complete, we want to call two. Once two's ajax call is complete, we want to call three.
#
# BUT, we don't want to just call our three functions in sequence, as this quick
# demo will show. Look at this sample function and think about what order
@christianhellsten
christianhellsten / unicorn
Created October 15, 2012 18:42 — forked from shapeshed/unicorn
Unicorn / Monit setup
#!/bin/sh
set -e
# Example init script, this can be used with nginx, too,
# since nginx and unicorn accept the same signals
# Feel free to change any of the following variables for your app:
TIMEOUT=${TIMEOUT-60}
APP_ROOT=/path/to/your/app/current
PID=$APP_ROOT/tmp/pids/unicorn.pid
ENVIRONMENT=production