TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Django Production Deployment and Development Using Git

73 pointsby jknuppover 13 years ago

6 comments

rlanderover 13 years ago
The global settings file is the single biggest hurdle, not only in django deployment, but also development. And it's been like this since I can first remember with no visible progress.<p>It sucks to keep track of dev/prod local files, it makes it hard to setup a simple script inside of a django environment, it makes multi tenant apps unnecessarily complex, app developers usually want to shove every single configuration option inside of it...<p>If anyone with more than a few hours of django development is doing split settings or something more complex, and even the official docs and best practices recommend doing so, why are we still stuck with it?<p>There are much saner ways to deal with configuration: Flask's[1] is one nice way, as is Padrino's[2].<p>As a Django dev, this is one of those things that actually makes me jealous of Rails, where the core devs are not afraid of breaking backwards compatibility for sanity's sake.<p>In my opinion it should be priority #1 for an overhaul.<p>[1] <a href="http://flask.pocoo.org/docs/config/" rel="nofollow">http://flask.pocoo.org/docs/config/</a> [2] <a href="http://www.padrinorb.com/guides/mounting-applications" rel="nofollow">http://www.padrinorb.com/guides/mounting-applications</a>
评论 #3557250 未加载
评论 #3557685 未加载
评论 #3557288 未加载
jpkover 13 years ago
I've been doing roughly this for a little while now, and it works pretty well. Particularly the bit about splitting the settings file. There are a few ways to do that, here[1].<p>[1] <a href="https://code.djangoproject.com/wiki/SplitSettings" rel="nofollow">https://code.djangoproject.com/wiki/SplitSettings</a>
Osmoseover 13 years ago
At Mozilla, we use a homegrown template called Playdoh[1][2] that includes split settings file, some sample deployment scripts, and lots of useful libraries that handle stuff like secure cookies, localization, strong password hashing, etc.<p>I'm not super-familiar with our deployment process, but I do know that we have internal git repos that hold our production and dev environments (like local settings) and use puppet for setting up servers.<p>[1]: Github: <a href="https://github.com/mozilla/playdoh" rel="nofollow">https://github.com/mozilla/playdoh</a><p>[2]: Docs: <a href="http://playdoh.readthedocs.org/en/latest/index.html" rel="nofollow">http://playdoh.readthedocs.org/en/latest/index.html</a>
评论 #3559645 未加载
hsparikhover 13 years ago
I am learning django/web development, and will likely be launching my app in the wild soon. A link that details out how to manage deployment and source code management using git would be tremendously helpful.
评论 #3557641 未加载
评论 #3556939 未加载
stargazer83over 13 years ago
We manage the deployments of our Django application, in multiple environments (production/staging/experimental/development) using Buildout. It probably is quite difficult to learn at first, but very rewarding once you get the hang of it. Deployment is all about being confident. And the confidence that Buildout has given us, is uncomparable to anything else.<p>A cool way to produce various settings/configurations, is using the Buildout recipe collective.recipe.genshi. This enables us to create settings based on templates, using buildout configuration parameters. Very flexible solution!
spleeyahover 13 years ago
As a Django developer/sysadmin myself, I'd be very interested to hear more details about how you deploy.
评论 #3556707 未加载