Design help: django deployment

44 views
Skip to first unread message

Jonathan Gazeley

unread,
Feb 10, 2015, 5:13:26 AM2/10/15
to puppet...@googlegroups.com
Hi folks,

The developers at my place are designing a new set of webapps, which will be written in Python/Django. This is new to us (our old stuff is nasty Perl) and I've been asked to look at how to deploy these new apps using Puppet.

The Django apps will be developed in Git repos and releases will be tagged so I am envisaging using puppetlabs/vcsrepo to deploy releases of the apps to the web server's filesystem. The developers want to use virtualenv to handle dependencies in their apps. Is there are a recommended method among other Puppet admins to deploy Django apps from git with virtualenv and have them served preferably with Apache or Nginx?

I can't find a monolithic module to do this on the Forge so if nobody has a wiser suggestion, I will probably write something using puppetlabs/vcsrepo, stankevich/python and puppetlabs/apache.

Thanks,
Jonathan

Charles Yeomans

unread,
Feb 10, 2015, 10:56:51 AM2/10/15
to puppet...@googlegroups.com
There are plenty of little problems you'll need to solve here. As for the server, my preference is to use Nginx and reverse-proxy to Apache + mod_wsgi.

A good way to set up the Django python stuff is to make one or more python packages and install them using pip. This approach works well with git, virtualenv and puppet.

Then you'll be left to deal with Django itself...


Charles Yeomans

Pete Brown

unread,
Feb 18, 2015, 4:07:24 PM2/18/15
to puppet-users

Hi Jonathan,

The puppetboard module uses stankevich/python to get it's underlying python bits setup so it might give you some ideas.
https://forge.puppetlabs.com/nibalizer/puppetboard

I haven't deployed python apps much myself but the ideas you had would be where I would start.

If you can't find anything decent I would see that as an opportunity to add your resulting module to puppet forge. :)

--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/54D9D9B0.2080804%40bristol.ac.uk.
For more options, visit https://groups.google.com/d/optout.

Jonathan Gazeley

unread,
Feb 19, 2015, 5:37:37 AM2/19/15
to puppet...@googlegroups.com
On 18/02/15 21:05, Pete Brown wrote:
> If you can't find anything decent I would see that as an opportunity
> to add your resulting module to puppet forge. :)

Indeed :) I couldn't find anything quite suitable so I started work on a
basic module.

https://forge.puppetlabs.com/jgazeley/django

Cheers,
Jonathan
Reply all
Reply to author
Forward
0 new messages