This file contains 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
from bottle import route | |
routes = ( | |
# path, function, http_method, name | |
('/', index_get, 'GET', 'index_get'), | |
('/', index_post, 'POST', 'index_post'), | |
) | |
setup_routes(routes) |
This file contains 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
15:40.09 Fri Apr 15 2011! ~/Work/geeves | |
bsmith@the-smiths-macbook!1042 E:2 S:1 | |
-> bin/geeves -V | |
Fabric 1.0.1 |
This file contains 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
kwargs = dict(((str(key), val) for key, val in args['keyword_args'].items())) |
This file contains 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
Taken from http://www.infrastructures.org/papers/bootstrap/bootstrap.html "Bootstrapping an Infrastructure" | |
Lots of important lessons in that paper. Many of them still relevant today. This one is important to remember when hiring a "devop". The context switch is pretty hardcore between the two people outlined below. Remember that. | |
Systems Administrator, or Infrastructure Architect? | |
There's a career slant to all of this. | |
Infrastructure architects typically develop themselves via a systems administration career track. That creates a dilemma. A systems administration background is crucial for the development of a good infrastructure architect, but we have found that the skillset, project time horizon, and coding habits needed by an infrastructure architect are often orthogonal to those of a systems administrator -- an architect is not the same animal as a senior sysadmin. |
This file contains 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
-bash-3.2# pip -q install uwsgi | |
Could not find .egg-info directory in install record for uwsgi | |
-bash-3.2# pip freeze | grep uwsgi | |
-bash-3.2# pip freeze | |
gunicorn==0.12.1 | |
meld3==0.6.7 | |
paster==0.6 | |
supervisor==3.0a10 | |
virtualenv==1.6 | |
wsgiref==0.1.2 |
This file contains 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
File "/usr/lib/python2.6/site-packages/setuptools-0.6c11-py2.6.egg/pkg_resources.py", line 666, in require |
This file contains 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
diff --git a/requests/models.py b/requests/models.py | |
index 2c3241d..689e7db 100644 | |
--- a/requests/models.py | |
+++ b/requests/models.py | |
@@ -135,13 +135,14 @@ class Request(object): | |
return opener.open | |
- def _build_response(self, resp): | |
+ def _build_response(self, resp, req): |
This file contains 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
[admin@ffcgx6an ~/uwsgi-0.9.7.2]$ make -f Makefile.Py27 | |
python2.7 uwsgiconfig.py --build | |
using profile: buildconf/default.ini | |
*** uWSGI compiling server core *** | |
gcc -c utils.c -o utils.o -O2 -Wall -Werror -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fno-strict-aliasing -DUWSGI_BUILD_DATE="\"25 May 2011 20:48:59\"" -DUWSGI_LOCK_USE_MUTEX -DUWSGI_EVENT_USE_PORT -DUWSGI_EVENT_TIMER_USE_PORT -DUWSGI_EVENT_FILEMONITOR_USE_PORT -DUWSGI_EMBEDDED -DUWSGI_UDP -DUWSGI_ASYNC -DUWSGI_MULTICAST -DUWSGI_MINTERPRETERS -DUWSGI_INI -DUWSGI_YAML -DUWSGI_LDAP -DUWSGI_SNMP -DUWSGI_THREADING -DUWSGI_SENDFILE -I/opt/local/include/libxml2 -I/opt/local/include -DUWSGI_XML -DUWSGI_XML_LIBXML2 -DUWSGI_PLUGIN_DIR=\".\" -DUWSGI_SPOOLER -DUWSGI_DECLARE_EMBEDDED_PLUGINS="UDEP(python);UDEP(ping);UDEP(nagios);UDEP(rpc);UDEP(fastrouter);UDEP(http);UDEP(ugreen);" -DUWSGI_LOAD_EMBEDDED_PLUGINS="ULEP(python);ULEP(ping);ULEP(nagios);ULEP(rpc);ULEP(fastrouter);ULEP(http);ULEP(ugreen);" | |
In file included from utils.c:1: | |
uwsgi.h:91:21: ifaddrs.h: N |
This file contains 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
[Wed, 08 Jun 2011 23:34:31 +0000] INFO: Run List expands to [shootq_app] | |
[Wed, 08 Jun 2011 23:34:31 +0000] INFO: Starting Chef Run for ffcgx6as.joyent.us | |
[Wed, 08 Jun 2011 23:34:32 +0000] INFO: Loading cookbooks [build-essential, pkgsrc, python, shootq_app] | |
[Wed, 08 Jun 2011 23:34:33 +0000] INFO: Storing updated cookbooks/shootq_app/recipes/default.rb in the cache. | |
[Wed, 08 Jun 2011 23:34:33 +0000] INFO: Processing remote_file[/var/chef/cache/distribute_setup.py] action create (python::pip line 25) | |
[Wed, 08 Jun 2011 23:34:33 +0000] INFO: Processing bash[install-pip] action run (python::pip line 31) | |
[Wed, 08 Jun 2011 23:34:33 +0000] INFO: Processing python_pip[virtualenv] action install (python::virtualenv line 23) | |
[Wed, 08 Jun 2011 23:34:33 +0000] INFO: Processing package[git] action install (shootq_app::default line 8) | |
[Wed, 08 Jun 2011 23:34:33 +0000] INFO: package[git] installed version | |
[Wed, 08 Jun 2011 23:34:33 +0000] INFO: Processing directory[/opt/shootq/bin] action create (shootq_app::default line 15 |
This file contains 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
# Before | |
%w{PIL tg.devtools}.each do |pkg| | |
python_pip "#{pkg}" do | |
virtualenv "/opt/shootq/shootq/" | |
action :install | |
end | |
end | |
python_pip "git+https://github.com/pecan/pecan.git" do | |
virtualenv "/opt/shootq/shootq/" |