Charm Needed: python-django (with WSGI container)

Bug #1012942 reported by Patrick Hetu on 2012-06-14
This bug affects 4 people
Affects Status Importance Assigned to Milestone
Juju Charms Collection

Bug Description

Following the instruction in this other django charm ticket:

I'm creating that new ticket from a new django charm that works with
WSGI container like the Gunicorn one:

Clint Byrum (clint-fewbar) wrote :

Hi Patrick, its great to review the other side of your django/wsgi charm. :)

* Cool use of SWIFT!


* Error checking. You do a lot of operations throughout your hooks, but no error checking is done. I'd like to see 'set -e' at the very least in your bash scripts. 'set -ue' would be even better. If you cannot do that, please assert why its ok to do all the operations even if some of the earlier ones failed.

* website-relation-joined: I've not seen 'domain' used in the http relation. Adding optional fields is ok, but this probably deserves some explanation.
* website-relation-joined: hostname -f should be changed to unit-get private-address
* hooks/start and hooks/stop are useless in this context with the wsgi subordinate doing all the resident daemon running, please remove them.

Fix these, and change the status to Fix Committed, and we should be able to get your charm promulgated.


* website-relation-joined: this does no relation-get, so it seems like it should be a joined only.
* a lot of the config parameters are ignored after install, this should be documented in their config.yaml description, as users should be able to expect that config parameters will be respected any time 'juju set' is used. Ideally all of that would be moved into config-changed anyway, so the service can be changed at will, but that can also make config-changed more complicated.
* pip does not cryptographically verify its downloads. While this is optional, since one doesn't have to use the pip requirements bit, it should include a warning in config.yaml that these are not as safe as using packaged software.
* config.yaml - you only support hg, git, bzr, and svn, please document this in the config.yaml description

Changed in charms:
status: New → Incomplete
Changed in charms:
status: Incomplete → Fix Released
status: Fix Released → Fix Committed
Clint Byrum (clint-fewbar) wrote :

Great stuff Patrick!

There was one thing left. I'd like to see website-relation-joined exit with an error if gunicorn is not available, since it doesn't know if it is being run by any other WSGI provider. Otherwise the relation will seem to establish itself, but not actually go.

This can be fixed in later updates though. :)


Changed in charms:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers