2 ms·
I would like to hear more about this paradigm if you have a minute.
by blorenz 3y ago
I would like to hear more about this paradigm if you have a minute.
- DangitBobby 3y agoIn your wsgi.py file, you specify which settings module to use when loading your WSGI application with, e.g., gunicorn. In your settings.py file, you can specify what your root url config is, e.g. a urls.py file which recursively defines all routes in you application. But nothing is stopping you from having n different settings files, e.g. settings/service1.py with n different urls.py files and loading them in n different wsgi.py files and serving them with n different gunicorn deployments. You can also do things like adjust the settings defined in your settings.py file to use a different url conf programatically based on environment variables. It is just python, after all.