Steps with explanations to set up a server using:
- Virtualenv
- Virtualenvwrapper
- Django
- Gunicorn
| curl -LI mazgi.com -o /dev/null -w '%{http_code}\n' -s |
| #!/usr/bin/php | |
| <?php | |
| $in = fopen('php://stdin', 'r'); | |
| $result=array(); | |
| $format='_.'; | |
| while($line=fgetcsv($in, 0, "\t")) { | |
| $result[]='|'.$format.implode('|'.$format, $line).'|'; | |
| $format=''; | |
| } | |
| fclose($in); |
| #!/bin/bash | |
| NAME="hello_app" # Name of the application | |
| DJANGODIR=/webapps/hello_django/hello # Django project directory | |
| SOCKFILE=/webapps/hello_django/run/gunicorn.sock # we will communicte using this unix socket | |
| USER=hello # the user to run as | |
| GROUP=webapps # the group to run as | |
| NUM_WORKERS=3 # how many worker processes should Gunicorn spawn | |
| DJANGO_SETTINGS_MODULE=hello.settings # which settings file should Django use | |
| DJANGO_WSGI_MODULE=hello.wsgi # WSGI module name |
| -- TermTheme.scpt | |
| -- Ken Hansen 02/2012 | |
| -- Sets theme of current terminal window/tab | |
| ----------------------- | |
| -- Arguments | |
| ----------------------- | |
| -- If a theme name is provided on the command line then set to that | |
| -- Example | |
| -- osascript TermTheme.scpt Grass |