Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proposed modernization and simplification #27

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Proposed modernization and simplification #27

wants to merge 2 commits into from

Conversation

nolsto
Copy link
Member

@nolsto nolsto commented Apr 25, 2024

I propose we get the project template back in working shape and get use out of it once again.

As a start I have done the following:

  • Base the template on the latest Django LTS release, 4.2.
  • Strip the very proscriptive base.html template of most of its structure and use of scripts and stylesheets.
  • Remove all fabric-related code and scripts.
  • Modernize pip requirements and associated settings configuration (sentry, django-libsass, etc.).

Additionally, I have addressed something I am often annoyed by in our current setup:
I have introduced a module settings_dev.py. This contains all generalized configuration specifically meant for development. settings_local.py wildcard imports it.

If the file exists, settings_local should still be the value of DJANGO_SETTINGS_MODULE, though it doesn't have to exist (settings_dev should be sufficient to setup Django for runserver).

settings_local contains all the development configuration specific to you personally. This should prevent the frequent issue of individual developers' untracked settings_local filling with necessary configuration, and then that configuration not making its way back into the settings_local.example.py to serve as a reference to others. Even if it does make it into the example file, other developers must be aware that they should always be looking at the example file for new settings. This is burdensome.

Also relating to settings modules, I have included settings_live.py. This module simply contains the base configuration for all sites that should live on the public internet and contains configuration relating to SSL and other non-debug settings. Separate settings_staging.py and settings_production.py modules import it.

Let me know your thoughts and feel free to review and/or add to this proposal.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants