Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@ashwoods
Created June 5, 2012 07:04
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save ashwoods/2873218 to your computer and use it in GitHub Desktop.
Save ashwoods/2873218 to your computer and use it in GitHub Desktop.
node "submitz" inherits default {
include django
include supervisor
django::resource::project {'submitz':
ensure => present,
location => '/opt/submitz/submitz',
source => 'git@github.com:xipax/submitz.git',
user => 'submitz',
}
django::resource::virtualenv {'submitz':
ensure => present,
location => '/opt/submitz/.virtualenvs/submitz',
user => 'submitz',
project => '/opt/submitz/submitz',
requirements => 'stable.pip',
require => Django::Resource::Project['submitz']
}
supervisor::service {"gunicorn-submitz":
ensure => running,
enable => true,
command => "/opt/submitz/.virtualenvs/submitz/bin/gunicorn_django -w 4 -b 0.0.0.0:9000",
chdir => '/opt/submitz/submitz/submitz',
user => "submitz",
autorestart => true,
redirect_stderr => true,
environment => 'LANG=en_US.UTF-8, LC_ALL=en_US.UTF-8, LC_LANG=en_US.UTF-8'
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment