<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0"><channel><atom:link rel="hub" href="http://tumblr.superfeedr.com/" xmlns:atom="http://www.w3.org/2005/Atom"/><description>Yo! I’m David Caplan. I’m a co-founder of  Dolbeau, the online mens fashion accessory company. Previously, I studied biochemistry at the University of Toronto. I’m a published scientist, hacker, and player of the occasional song.</description><title>Proteins, Code &amp; Fashion</title><generator>Tumblr (3.0; @davecap)</generator><link>http://www.davecap.com/</link><item><title>“Feudal Japan’s sartorial laws”… this is...</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m5054c8OFx1r1l4hvo1_500.png"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;“Feudal Japan’s sartorial laws”… this is what happens when you study the history of fashion in Japan. Dolbeau kills it with SEO!&lt;/p&gt;</description><link>http://www.davecap.com/post/24273547138</link><guid>http://www.davecap.com/post/24273547138</guid><pubDate>Sat, 02 Jun 2012 14:09:48 -0400</pubDate><category>japan</category><category>dolbeau</category><category>google</category></item><item><title>Just a little tidbit on the market share of Canadian-made...</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m4wg7cfCv21r1l4hvo1_500.png"/&gt;&lt;br/&gt; Destination of Canadian apparel exports&lt;br/&gt;&lt;br/&gt; &lt;img src="http://25.media.tumblr.com/tumblr_m4wg7cfCv21r1l4hvo2_500.png"/&gt;&lt;br/&gt; US apparel market share&lt;br/&gt;&lt;br/&gt; &lt;p&gt;Just a little tidbit on the market share of Canadian-made apparel. It turns out that 84% of all clothing made in Canada is exported to the USA, accounting for only 1% of all apparel sold in the USA. This doesn’t include apparel made overseas by Canadian-owned companies.&lt;/p&gt;

&lt;p&gt;In case you’re wondering, 80% of clothing sold in Canada is made elsewhere (not sure how much of that is made in the USA, but probably not that much). Canadians seem to buy more locally-made clothing than Americans though (per capita), which is something that we’ve noticed at Dolbeau.&lt;/p&gt;</description><link>http://www.davecap.com/post/24138576486</link><guid>http://www.davecap.com/post/24138576486</guid><pubDate>Thu, 31 May 2012 14:18:00 -0400</pubDate></item><item><title>Julien Smith modeling his collabo edition (Taken with instagram)</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m4un5yx9Gd1r1l4hvo1_500.jpg"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;Julien Smith modeling his collabo edition (Taken with &lt;a href="http://instagr.am"&gt;instagram&lt;/a&gt;)&lt;/p&gt;</description><link>http://www.davecap.com/post/24074195725</link><guid>http://www.davecap.com/post/24074195725</guid><pubDate>Wed, 30 May 2012 14:53:58 -0400</pubDate></item><item><title>Today dolbeau.ca was compared to apple.com in this random...</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m3vjid7Kj41r1l4hvo1_500.png"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;Today dolbeau.ca was compared to apple.com in this random stackoverflow question. Very flattering for us all here at Dolbeau HQ.&lt;/p&gt;</description><link>http://www.davecap.com/post/22854056999</link><guid>http://www.davecap.com/post/22854056999</guid><pubDate>Fri, 11 May 2012 15:58:59 -0400</pubDate><category>dolbeau</category></item><item><title>Tie pyramid (Taken with instagram)</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m3tnxlFEbP1r1l4hvo1_500.jpg"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;Tie pyramid (Taken with &lt;a href="http://instagr.am"&gt;instagram&lt;/a&gt;)&lt;/p&gt;</description><link>http://www.davecap.com/post/22791944276</link><guid>http://www.davecap.com/post/22791944276</guid><pubDate>Thu, 10 May 2012 15:39:20 -0400</pubDate></item><item><title>Knitting machines (Taken with instagram)</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m3eqj5aeCR1r1l4hvo1_500.jpg"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;Knitting machines (Taken with &lt;a href="http://instagr.am"&gt;instagram&lt;/a&gt;)&lt;/p&gt;</description><link>http://www.davecap.com/post/22264223787</link><guid>http://www.davecap.com/post/22264223787</guid><pubDate>Wed, 02 May 2012 14:11:29 -0400</pubDate></item><item><title>C’est moi</title><description>&lt;img src="http://24.media.tumblr.com/tumblr_m3b4ceQMdM1qcyb97o1_500.jpg"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;C’est moi&lt;/p&gt;</description><link>http://www.davecap.com/post/22136696610</link><guid>http://www.davecap.com/post/22136696610</guid><pubDate>Mon, 30 Apr 2012 15:33:03 -0400</pubDate></item><item><title>Graph of Dolbeau newsletter subscribers… now all we need...</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m37k2tnOCJ1r1l4hvo1_500.png"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;Graph of Dolbeau newsletter subscribers… now all we need is the rest of the hockey stick :)&lt;/p&gt;</description><link>http://www.davecap.com/post/22002041333</link><guid>http://www.davecap.com/post/22002041333</guid><pubDate>Sat, 28 Apr 2012 17:08:53 -0400</pubDate><category>dolbeau</category><category>stats</category></item><item><title>Sexy Dolbeau multicolor bow tie…. coming soon!</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m355k0yIoM1r1l4z2o1_500.jpg"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;Sexy Dolbeau multicolor bow tie…. coming soon!&lt;/p&gt;</description><link>http://www.davecap.com/post/21929755529</link><guid>http://www.davecap.com/post/21929755529</guid><pubDate>Fri, 27 Apr 2012 16:47:18 -0400</pubDate><category>menswear</category><category>dolbeau</category></item><item><title>Dolbeau website in 3D… courtesy of Firefox.</title><description>&lt;img src="http://24.media.tumblr.com/tumblr_m320dkq1qv1r1l4hvo1_500.png"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;Dolbeau website in 3D… courtesy of Firefox.&lt;/p&gt;</description><link>http://www.davecap.com/post/21802254695</link><guid>http://www.davecap.com/post/21802254695</guid><pubDate>Wed, 25 Apr 2012 17:15:20 -0400</pubDate><category>dolbeau</category></item><item><title>Provision &amp; deploy a simple Django stack on Debian 6 using Fabric &amp; Cuisine</title><description>&lt;p&gt;Warning: This post is for people who know what Python, Django, and Debian are.&lt;/p&gt;

&lt;p&gt;It turns out that most people ever only need a single VPS node (or less) for their Django site. When it comes to small sites, using Chef and Puppet for deployment is kind of overkill. In our previous iteration at &lt;a href="http://www.dolbeau.ca"&gt;Dolbeau&lt;/a&gt; I implemented Chef with the &lt;a href="http://wiki.opscode.com/display/chef/Deploy+Resource"&gt;Deploy Resource&lt;/a&gt;. It worked alright, except for the fact that my deploys took way too long, not to mention it was super overcomplicated and scary when it failed. I wanted to convert my huge ass Chef deployment into a tiny &lt;a href="http://fabfile.org"&gt;Fabric&lt;/a&gt; script (with the help of &lt;a href="https://github.com/sebastien/cuisine"&gt;Cuisine&lt;/a&gt;), so I did!&lt;/p&gt;

&lt;p&gt;You can find it in a &lt;a href="http://github.com/davecap/deploy-django"&gt;Github repo called deploy-django&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The stack is composed of:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;Nginx&lt;/li&gt;
&lt;li&gt;Gunicorn&lt;/li&gt;
&lt;li&gt;Django&lt;/li&gt;
&lt;li&gt;Memcached&lt;/li&gt;
&lt;li&gt;Postgresql&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;Supervisord is basically optional, but you need to edit the fabfile. Right now I personally just restart guncorn using a kill -HUP during the deploy process. This seems to work fine for my purposes. I&amp;#8217;ve included an example init script in the provision folder.&lt;/p&gt;

&lt;p&gt;To use the fabfile, you first need to install the requirements:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;pip install -r requirements.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Then, edit the deploy_settings.py file:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;APP_NAME = the name of your python app
APP_REPO = the git repo
APP_REPO_BRANCH = the branch you want to deploy
APP_HOSTS = a list of hosts
REMOTE_USER, REMOTE_GROUP = the linux user that should own the deploy directory on the server

DJANGO_STATIC_ROOT = the directory name of your static_root in your app
DJANGO_MEDIA_ROOT = the directory name of your media_root in your app

DEBIAN_PACKAGES = a list of debian packages to install, the default list contains a bunch of things that you may not need

DEPLOY_TREE = defines the deploy directory tree. The default deploy tree creates a /srv/&amp;lt;APP_NAME&amp;gt; for your app.


DEPLOY_TREE = {
    APP_NAME: {
        'releases': {},
        'shared': {
            'logs': {},
            'media_root': {},
            DJANGO_STATIC_ROOT: {}
        }
    }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Then, you edit the server config files in the provision directory. The provision directory is structured as if it is the root directory of your server&amp;#8217;s disk and it contains basic config files for your stack. You will need to edit these files (and rename some of them) before trying to deploy, they are NOT templates.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;/etc/
    rc.local
    init.d/myapp
    gunicorn/myapp.conf.py
    nginx/
        nginx.conf
        sites-available/myapp
    postgresql/8.4/main/postgresql.conf
    supervisor/conf.d/myapp.conf
/srv/myapp/shared/settings_local.py
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Then you can try to initialize, provision and deploy:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;fab initialize
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;This will set up the required user and inject your public ssh-key for passwordless login.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;fab provision
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;This will install the packages and set up the server config files&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;fab deploy
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;This will deploy your app!&lt;/p&gt;

&lt;p&gt;It should all work&amp;#8230; if it doesn&amp;#8217;t then feel free to file an issue or fork the repo.&lt;/p&gt;</description><link>http://www.davecap.com/post/21780403407</link><guid>http://www.davecap.com/post/21780403407</guid><pubDate>Wed, 25 Apr 2012 09:06:20 -0400</pubDate><category>python</category><category>django</category><category>deploy</category><category>geeks</category></item><item><title>Photo shoot with spence (Taken with instagram)</title><description>&lt;img src="http://24.media.tumblr.com/tumblr_m2r5ovF3oT1r1l4hvo1_500.jpg"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;Photo shoot with spence (Taken with &lt;a href="http://instagr.am"&gt;instagram&lt;/a&gt;)&lt;/p&gt;</description><link>http://www.davecap.com/post/21409131957</link><guid>http://www.davecap.com/post/21409131957</guid><pubDate>Thu, 19 Apr 2012 20:36:31 -0400</pubDate></item><item><title>Dolbeau photo shoot! (Taken with instagram)</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m2r37bKuZa1r1l4hvo1_500.jpg"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;Dolbeau photo shoot! (Taken with &lt;a href="http://instagr.am"&gt;instagram&lt;/a&gt;)&lt;/p&gt;</description><link>http://www.davecap.com/post/21405727971</link><guid>http://www.davecap.com/post/21405727971</guid><pubDate>Thu, 19 Apr 2012 19:42:47 -0400</pubDate></item><item><title>Pisco sours @ Big in Japan (Taken with instagram)</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m2lnz3pdL71r1l4hvo1_500.jpg"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;Pisco sours @ Big in Japan (Taken with &lt;a href="http://instagr.am"&gt;instagram&lt;/a&gt;)&lt;/p&gt;</description><link>http://www.davecap.com/post/21243812755</link><guid>http://www.davecap.com/post/21243812755</guid><pubDate>Mon, 16 Apr 2012 21:25:50 -0400</pubDate></item><item><title>Photo</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m22pfxfRhI1qcyb97o1_500.jpg"/&gt;&lt;br/&gt;&lt;br/&gt;</description><link>http://www.davecap.com/post/20605589284</link><guid>http://www.davecap.com/post/20605589284</guid><pubDate>Fri, 06 Apr 2012 15:50:40 -0400</pubDate><category>Dolbeau</category></item><item><title>It’s a Dolbeau super-top-secret prototype!!</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m0naa2zNID1qcyb97o1_500.jpg"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;It’s a Dolbeau super-top-secret prototype!!&lt;/p&gt;</description><link>http://www.davecap.com/post/19087663493</link><guid>http://www.davecap.com/post/19087663493</guid><pubDate>Sat, 10 Mar 2012 19:27:56 -0500</pubDate><category>dolbeau</category><category>ties</category><category>menswear</category></item><item><title>Megan in action (Taken with instagram)</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m0lhn6ZVrL1r1l4hvo1_500.jpg"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;Megan in action (Taken with &lt;a href="http://instagr.am"&gt;instagram&lt;/a&gt;)&lt;/p&gt;</description><link>http://www.davecap.com/post/18979939596</link><guid>http://www.davecap.com/post/18979939596</guid><pubDate>Thu, 08 Mar 2012 21:01:54 -0500</pubDate></item><item><title>Bracelet designers @ Dolbeau (Taken with instagram)</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m09ulot4DB1r1l4hvo1_500.jpg"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;Bracelet designers @ Dolbeau (Taken with &lt;a href="http://instagr.am"&gt;instagram&lt;/a&gt;)&lt;/p&gt;</description><link>http://www.davecap.com/post/18614975438</link><guid>http://www.davecap.com/post/18614975438</guid><pubDate>Fri, 02 Mar 2012 14:10:36 -0500</pubDate></item><item><title>2002 Tii x2 (Taken with instagram)</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m04qsuF4We1r1l4hvo1_500.jpg"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;2002 Tii x2 (Taken with &lt;a href="http://instagr.am"&gt;instagram&lt;/a&gt;)&lt;/p&gt;</description><link>http://www.davecap.com/post/18466833831</link><guid>http://www.davecap.com/post/18466833831</guid><pubDate>Tue, 28 Feb 2012 20:00:30 -0500</pubDate></item><item><title>New bow tie? (Taken with instagram)</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_m02lh4kRsX1r1l4hvo1_500.jpg"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;New bow tie? (Taken with &lt;a href="http://instagr.am"&gt;instagram&lt;/a&gt;)&lt;/p&gt;</description><link>http://www.davecap.com/post/18394303724</link><guid>http://www.davecap.com/post/18394303724</guid><pubDate>Mon, 27 Feb 2012 16:10:16 -0500</pubDate></item></channel></rss>

