treeherder/deployment
Ed Morley 1af312e0cc Bug 1175432 - Use dj-database-url to simplify DB environment variables
dj-database-url extracts DB host, port, username, password and database
name from the env variable 'DATABASE_URL' (unless another env variable
name is specified). If the env variable is not defined, it falls back to
the default passed to dj_database_url.config().

This means for Heroku and similar we can replace the multiple DB env
variables with just one URL for default & one for read_only.

This also effectively makes the setting of the read only DB variable
mandatory for stage/production/heroku, since DEFAULT_DATABASE_URL won't
be valid for them - so prevents us inadvertently not using the read only
DB.

The deployment script also had to be updated, so that we set the
prod/stage-specific environment variables before using manage.py, since
dj-database-url cannot rely on what's in the stage/prod local.py config
(which isn't a bad thing, since we're deprecating that file).
2015-07-15 14:58:46 +01:00
..
aws Bug 1145606 - Setup treeherder to deploy on heroku 2015-05-14 13:54:41 +01:00
supervisord Bug 1056877 - Update links & puppet/Vagrant config for new repo name 2015-04-20 22:00:04 +01:00
update Bug 1175432 - Use dj-database-url to simplify DB environment variables 2015-07-15 14:58:46 +01:00