mirror of
https://github.com/zulip/zulip.git
synced 2026-06-21 21:32:29 +08:00
We recently changed our droplet setup such that their host names no longer include zulipdev.org. This caused a few things to break. The particular symptom that this commit fixes is that we were trying to server static assets from showell:9991 instead of showell.zulipdev.org:9991, which meant that you couldn't use the app locally. (The server would start, but the site's pretty unusable without static assets.) Now we rely 100% on `dev_settings.py` to set `EXTERNAL_HOST` for any droplet users who don't set that var in their own environment. That allows us to remove some essentially duplicate code in `run-dev.py`. We also set `IS_DEV_DROPLET` explicitly, so that other code doesn't have to make inferences or duplicate logic to detemine whether we're a droplet or not. And then in `settings.py` we use `IS_DEV_DROPLET` to know that we can use a prod-like method of calculating `STATIC_URL`, instead of hard coding `localhost`. We may want to iterate on this further--this was sort of a quick fix to get droplets functional again. It's possible we can re-configure droplets to have folks get reasonable `EXTERNAL_HOST` settings in their bash profiles, or something like that, although that may have its own tradeoffs. |
||
|---|---|---|
| .. | ||
| jinja2 | ||
| __init__.py | ||
| backends.py | ||
| config.py | ||
| default_settings.py | ||
| dev_settings.py | ||
| dev_urls.py | ||
| email_backends.py | ||
| legacy_urls.py | ||
| prod_settings_template.py | ||
| settings.py | ||
| slack_importer_test_settings.py | ||
| terms.md.template | ||
| test_settings.py | ||
| urls.py | ||
| wsgi.py | ||