mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2025-08-13 16:34:52 +03:00
Merge branch 'master' into pyup-update-django-storages-1.13.2-to-1.14
This commit is contained in:
commit
e0d7eee13a
5
.github/contributors.json
vendored
5
.github/contributors.json
vendored
|
@ -1463,5 +1463,10 @@
|
||||||
"name": "itisnotyourenv",
|
"name": "itisnotyourenv",
|
||||||
"github_login": "itisnotyourenv",
|
"github_login": "itisnotyourenv",
|
||||||
"twitter_username": ""
|
"twitter_username": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Vageeshan Mankala",
|
||||||
|
"github_login": "vagi8",
|
||||||
|
"twitter_username": ""
|
||||||
}
|
}
|
||||||
]
|
]
|
6
.github/workflows/ci.yml
vendored
6
.github/workflows/ci.yml
vendored
|
@ -22,7 +22,7 @@ jobs:
|
||||||
name: "pytest ${{ matrix.os }}"
|
name: "pytest ${{ matrix.os }}"
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v4
|
||||||
- uses: actions/setup-python@v4
|
- uses: actions/setup-python@v4
|
||||||
with:
|
with:
|
||||||
python-version: "3.11"
|
python-version: "3.11"
|
||||||
|
@ -53,7 +53,7 @@ jobs:
|
||||||
COMPOSE_DOCKER_CLI_BUILD: 1
|
COMPOSE_DOCKER_CLI_BUILD: 1
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v4
|
||||||
- uses: actions/setup-python@v4
|
- uses: actions/setup-python@v4
|
||||||
with:
|
with:
|
||||||
python-version: "3.11"
|
python-version: "3.11"
|
||||||
|
@ -97,7 +97,7 @@ jobs:
|
||||||
DATABASE_URL: "postgres://postgres:postgres@localhost:5432/postgres"
|
DATABASE_URL: "postgres://postgres:postgres@localhost:5432/postgres"
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v4
|
||||||
- uses: actions/setup-python@v4
|
- uses: actions/setup-python@v4
|
||||||
with:
|
with:
|
||||||
python-version: "3.11"
|
python-version: "3.11"
|
||||||
|
|
2
.github/workflows/django-issue-checker.yml
vendored
2
.github/workflows/django-issue-checker.yml
vendored
|
@ -16,7 +16,7 @@ jobs:
|
||||||
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v4
|
||||||
- uses: actions/setup-python@v4
|
- uses: actions/setup-python@v4
|
||||||
with:
|
with:
|
||||||
python-version: "3.11"
|
python-version: "3.11"
|
||||||
|
|
2
.github/workflows/pre-commit-autoupdate.yml
vendored
2
.github/workflows/pre-commit-autoupdate.yml
vendored
|
@ -21,7 +21,7 @@ jobs:
|
||||||
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v4
|
||||||
- uses: actions/setup-python@v4
|
- uses: actions/setup-python@v4
|
||||||
with:
|
with:
|
||||||
python-version: "3.11"
|
python-version: "3.11"
|
||||||
|
|
2
.github/workflows/update-changelog.yml
vendored
2
.github/workflows/update-changelog.yml
vendored
|
@ -14,7 +14,7 @@ jobs:
|
||||||
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Set up Python
|
- name: Set up Python
|
||||||
uses: actions/setup-python@v4
|
uses: actions/setup-python@v4
|
||||||
|
|
2
.github/workflows/update-contributors.yml
vendored
2
.github/workflows/update-contributors.yml
vendored
|
@ -17,7 +17,7 @@ jobs:
|
||||||
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Set up Python
|
- name: Set up Python
|
||||||
uses: actions/setup-python@v4
|
uses: actions/setup-python@v4
|
||||||
|
|
|
@ -30,7 +30,7 @@ repos:
|
||||||
exclude: hooks/
|
exclude: hooks/
|
||||||
|
|
||||||
- repo: https://github.com/psf/black
|
- repo: https://github.com/psf/black
|
||||||
rev: 23.7.0
|
rev: 23.9.1
|
||||||
hooks:
|
hooks:
|
||||||
- id: black
|
- id: black
|
||||||
|
|
||||||
|
|
36
CHANGELOG.md
36
CHANGELOG.md
|
@ -3,6 +3,42 @@ All enhancements and patches to Cookiecutter Django will be documented in this f
|
||||||
|
|
||||||
<!-- GENERATOR_PLACEHOLDER -->
|
<!-- GENERATOR_PLACEHOLDER -->
|
||||||
|
|
||||||
|
## 2023.09.08
|
||||||
|
|
||||||
|
|
||||||
|
### Updated
|
||||||
|
|
||||||
|
- Update pytest to 7.4.2 ([#4573](https://github.com/cookiecutter/cookiecutter-django/pull/4573))
|
||||||
|
|
||||||
|
## 2023.09.07
|
||||||
|
|
||||||
|
|
||||||
|
### Updated
|
||||||
|
|
||||||
|
- Update django-allauth to 0.56.0 ([#4571](https://github.com/cookiecutter/cookiecutter-django/pull/4571))
|
||||||
|
|
||||||
|
## 2023.09.06
|
||||||
|
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- Replace Mailhog with Mailpit ([#4551](https://github.com/cookiecutter/cookiecutter-django/pull/4551))
|
||||||
|
|
||||||
|
### Updated
|
||||||
|
|
||||||
|
- Update sphinx to 7.2.5 ([#4569](https://github.com/cookiecutter/cookiecutter-django/pull/4569))
|
||||||
|
|
||||||
|
- Bump actions/checkout from 3 to 4 ([#4565](https://github.com/cookiecutter/cookiecutter-django/pull/4565))
|
||||||
|
|
||||||
|
- Update coverage to 7.3.1 ([#4567](https://github.com/cookiecutter/cookiecutter-django/pull/4567))
|
||||||
|
|
||||||
|
## 2023.09.04
|
||||||
|
|
||||||
|
|
||||||
|
### Updated
|
||||||
|
|
||||||
|
- Update django to 4.2.5 ([#4563](https://github.com/cookiecutter/cookiecutter-django/pull/4563))
|
||||||
|
|
||||||
## 2023.09.03
|
## 2023.09.03
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1944,6 +1944,13 @@ Listed in alphabetical order.
|
||||||
</td>
|
</td>
|
||||||
<td>egregors</td>
|
<td>egregors</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>Vageeshan Mankala</td>
|
||||||
|
<td>
|
||||||
|
<a href="https://github.com/vagi8">vagi8</a>
|
||||||
|
</td>
|
||||||
|
<td></td>
|
||||||
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>vascop</td>
|
<td>vascop</td>
|
||||||
<td>
|
<td>
|
||||||
|
|
|
@ -45,7 +45,7 @@ _These features can be enabled during initial project setup._
|
||||||
|
|
||||||
- Serve static files from Amazon S3, Google Cloud Storage, Azure Storage or [Whitenoise](https://whitenoise.readthedocs.io/)
|
- Serve static files from Amazon S3, Google Cloud Storage, Azure Storage or [Whitenoise](https://whitenoise.readthedocs.io/)
|
||||||
- Configuration for [Celery](https://docs.celeryq.dev) and [Flower](https://github.com/mher/flower) (the latter in Docker setup only)
|
- Configuration for [Celery](https://docs.celeryq.dev) and [Flower](https://github.com/mher/flower) (the latter in Docker setup only)
|
||||||
- Integration with [MailHog](https://github.com/mailhog/MailHog) for local email testing
|
- Integration with [Mailpit](https://github.com/axllent/mailpit/) for local email testing
|
||||||
- Integration with [Sentry](https://sentry.io/welcome/) for error logging
|
- Integration with [Sentry](https://sentry.io/welcome/) for error logging
|
||||||
|
|
||||||
## Constraints
|
## Constraints
|
||||||
|
@ -165,7 +165,7 @@ Answer the prompts with your own desired [options](http://cookiecutter-django.re
|
||||||
4 - Webpack
|
4 - Webpack
|
||||||
Choose from 1, 2, 3, 4 [1]: 1
|
Choose from 1, 2, 3, 4 [1]: 1
|
||||||
use_celery [n]: y
|
use_celery [n]: y
|
||||||
use_mailhog [n]: n
|
use_mailpit [n]: n
|
||||||
use_sentry [n]: y
|
use_sentry [n]: y
|
||||||
use_whitenoise [n]: n
|
use_whitenoise [n]: n
|
||||||
use_heroku [n]: y
|
use_heroku [n]: y
|
||||||
|
|
|
@ -35,7 +35,7 @@
|
||||||
"use_drf": "n",
|
"use_drf": "n",
|
||||||
"frontend_pipeline": ["None", "Django Compressor", "Gulp", "Webpack"],
|
"frontend_pipeline": ["None", "Django Compressor", "Gulp", "Webpack"],
|
||||||
"use_celery": "n",
|
"use_celery": "n",
|
||||||
"use_mailhog": "n",
|
"use_mailpit": "n",
|
||||||
"use_sentry": "n",
|
"use_sentry": "n",
|
||||||
"use_whitenoise": "n",
|
"use_whitenoise": "n",
|
||||||
"use_heroku": "n",
|
"use_heroku": "n",
|
||||||
|
|
|
@ -191,16 +191,16 @@ The ``container_name`` from the yml file can be used to check on containers with
|
||||||
|
|
||||||
Notice that the ``container_name`` is generated dynamically using your project slug as a prefix
|
Notice that the ``container_name`` is generated dynamically using your project slug as a prefix
|
||||||
|
|
||||||
Mailhog
|
Mailpit
|
||||||
~~~~~~~
|
~~~~~~~
|
||||||
|
|
||||||
When developing locally you can go with MailHog_ for email testing provided ``use_mailhog`` was set to ``y`` on setup. To proceed,
|
When developing locally you can go with Mailpit_ for email testing provided ``use_mailpit`` was set to ``y`` on setup. To proceed,
|
||||||
|
|
||||||
#. make sure ``<project_slug>_local_mailhog`` container is up and running;
|
#. make sure ``<project_slug>_local_mailpit`` container is up and running;
|
||||||
|
|
||||||
#. open up ``http://127.0.0.1:8025``.
|
#. open up ``http://127.0.0.1:8025``.
|
||||||
|
|
||||||
.. _Mailhog: https://github.com/mailhog/MailHog/
|
.. _Mailpit: https://github.com/axllent/mailpit/
|
||||||
|
|
||||||
.. _`CeleryTasks`:
|
.. _`CeleryTasks`:
|
||||||
|
|
||||||
|
|
|
@ -99,39 +99,37 @@ First things first.
|
||||||
Setup Email Backend
|
Setup Email Backend
|
||||||
-------------------
|
-------------------
|
||||||
|
|
||||||
MailHog
|
Mailpit
|
||||||
~~~~~~~
|
~~~~~~~
|
||||||
|
|
||||||
.. note:: In order for the project to support MailHog_ it must have been bootstrapped with ``use_mailhog`` set to ``y``.
|
.. note:: In order for the project to support Mailpit_ it must have been bootstrapped with ``use_mailpit`` set to ``y``.
|
||||||
|
|
||||||
MailHog is used to receive emails during development, it is written in Go and has no external dependencies.
|
Mailpit is used to receive emails during development, it is written in Go and has no external dependencies.
|
||||||
|
|
||||||
For instance, one of the packages we depend upon, ``django-allauth`` sends verification emails to new users signing up as well as to the existing ones who have not yet verified themselves.
|
For instance, one of the packages we depend upon, ``django-allauth`` sends verification emails to new users signing up as well as to the existing ones who have not yet verified themselves.
|
||||||
|
|
||||||
#. `Download the latest MailHog release`_ for your OS.
|
#. `Download the latest Mailpit release`_ for your OS.
|
||||||
|
|
||||||
#. Rename the build to ``MailHog``.
|
#. Copy the binary file to the project root.
|
||||||
|
|
||||||
#. Copy the file to the project root.
|
|
||||||
|
|
||||||
#. Make it executable: ::
|
#. Make it executable: ::
|
||||||
|
|
||||||
$ chmod +x MailHog
|
$ chmod +x mailpit
|
||||||
|
|
||||||
#. Spin up another terminal window and start it there: ::
|
#. Spin up another terminal window and start it there: ::
|
||||||
|
|
||||||
./MailHog
|
./mailpit
|
||||||
|
|
||||||
#. Check out `<http://127.0.0.1:8025/>`_ to see how it goes.
|
#. Check out `<http://127.0.0.1:8025/>`_ to see how it goes.
|
||||||
|
|
||||||
Now you have your own mail server running locally, ready to receive whatever you send it.
|
Now you have your own mail server running locally, ready to receive whatever you send it.
|
||||||
|
|
||||||
.. _`Download the latest MailHog release`: https://github.com/mailhog/MailHog
|
.. _`Download the latest Mailpit release`: https://github.com/axllent/mailpit
|
||||||
|
|
||||||
Console
|
Console
|
||||||
~~~~~~~
|
~~~~~~~
|
||||||
|
|
||||||
.. note:: If you have generated your project with ``use_mailhog`` set to ``n`` this will be a default setup.
|
.. note:: If you have generated your project with ``use_mailpit`` set to ``n`` this will be a default setup.
|
||||||
|
|
||||||
Alternatively, deliver emails over console via ``EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend'``.
|
Alternatively, deliver emails over console via ``EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend'``.
|
||||||
|
|
||||||
|
|
|
@ -115,8 +115,8 @@ Both Gulp and Webpack support Bootstrap recompilation with real-time variables a
|
||||||
use_celery:
|
use_celery:
|
||||||
Indicates whether the project should be configured to use Celery_.
|
Indicates whether the project should be configured to use Celery_.
|
||||||
|
|
||||||
use_mailhog:
|
use_mailpit:
|
||||||
Indicates whether the project should be configured to use MailHog_.
|
Indicates whether the project should be configured to use Mailpit_.
|
||||||
|
|
||||||
use_sentry:
|
use_sentry:
|
||||||
Indicates whether the project should be configured to use Sentry_.
|
Indicates whether the project should be configured to use Sentry_.
|
||||||
|
@ -185,7 +185,7 @@ debug:
|
||||||
|
|
||||||
.. _Celery: https://github.com/celery/celery
|
.. _Celery: https://github.com/celery/celery
|
||||||
|
|
||||||
.. _MailHog: https://github.com/mailhog/MailHog
|
.. _Mailpit: https://github.com/axllent/mailpit
|
||||||
|
|
||||||
.. _Sentry: https://github.com/getsentry/sentry
|
.. _Sentry: https://github.com/getsentry/sentry
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
sphinx==6.2.1
|
sphinx==7.2.5
|
||||||
sphinx-rtd-theme==1.2.2
|
sphinx-rtd-theme==1.3.0
|
||||||
myst-parser==2.0.0
|
myst-parser==2.0.0
|
||||||
|
|
|
@ -4,7 +4,7 @@ binaryornot==0.4.4
|
||||||
|
|
||||||
# Code quality
|
# Code quality
|
||||||
# ------------------------------------------------------------------------------
|
# ------------------------------------------------------------------------------
|
||||||
black==23.7.0
|
black==23.9.1
|
||||||
isort==5.12.0
|
isort==5.12.0
|
||||||
flake8==6.1.0
|
flake8==6.1.0
|
||||||
django-upgrade==1.14.1
|
django-upgrade==1.14.1
|
||||||
|
@ -13,8 +13,8 @@ pre-commit==3.4.0
|
||||||
|
|
||||||
# Testing
|
# Testing
|
||||||
# ------------------------------------------------------------------------------
|
# ------------------------------------------------------------------------------
|
||||||
tox==4.11.1
|
tox==4.11.3
|
||||||
pytest==7.4.1
|
pytest==7.4.2
|
||||||
pytest-xdist==3.3.1
|
pytest-xdist==3.3.1
|
||||||
pytest-cookies==0.7.0
|
pytest-cookies==0.7.0
|
||||||
pytest-instafail==0.5.0
|
pytest-instafail==0.5.0
|
||||||
|
@ -23,6 +23,6 @@ pyyaml==6.0.1
|
||||||
# Scripting
|
# Scripting
|
||||||
# ------------------------------------------------------------------------------
|
# ------------------------------------------------------------------------------
|
||||||
PyGithub==1.59.1
|
PyGithub==1.59.1
|
||||||
gitpython==3.1.34
|
gitpython==3.1.35
|
||||||
jinja2==3.1.2
|
jinja2==3.1.2
|
||||||
requests==2.31.0
|
requests==2.31.0
|
||||||
|
|
2
setup.py
2
setup.py
|
@ -5,7 +5,7 @@ except ImportError:
|
||||||
from distutils.core import setup
|
from distutils.core import setup
|
||||||
|
|
||||||
# We use calendar versioning
|
# We use calendar versioning
|
||||||
version = "2023.09.03"
|
version = "2023.09.08"
|
||||||
|
|
||||||
with open("README.md") as readme_file:
|
with open("README.md") as readme_file:
|
||||||
long_description = readme_file.read()
|
long_description = readme_file.read()
|
||||||
|
|
|
@ -115,8 +115,8 @@ SUPPORTED_COMBINATIONS = [
|
||||||
{"frontend_pipeline": "Webpack"},
|
{"frontend_pipeline": "Webpack"},
|
||||||
{"use_celery": "y"},
|
{"use_celery": "y"},
|
||||||
{"use_celery": "n"},
|
{"use_celery": "n"},
|
||||||
{"use_mailhog": "y"},
|
{"use_mailpit": "y"},
|
||||||
{"use_mailhog": "n"},
|
{"use_mailpit": "n"},
|
||||||
{"use_sentry": "y"},
|
{"use_sentry": "y"},
|
||||||
{"use_sentry": "n"},
|
{"use_sentry": "n"},
|
||||||
{"use_whitenoise": "y"},
|
{"use_whitenoise": "y"},
|
||||||
|
|
|
@ -23,7 +23,7 @@ jobs:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout Code Repository
|
- name: Checkout Code Repository
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Set up Python
|
- name: Set up Python
|
||||||
uses: actions/setup-python@v4
|
uses: actions/setup-python@v4
|
||||||
|
@ -65,7 +65,7 @@ jobs:
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout Code Repository
|
- name: Checkout Code Repository
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v4
|
||||||
{%- if cookiecutter.use_docker == 'y' %}
|
{%- if cookiecutter.use_docker == 'y' %}
|
||||||
|
|
||||||
- name: Build the Stack
|
- name: Build the Stack
|
||||||
|
|
4
{{cookiecutter.project_slug}}/.gitignore
vendored
4
{{cookiecutter.project_slug}}/.gitignore
vendored
|
@ -329,8 +329,8 @@ tags
|
||||||
dump.rdb
|
dump.rdb
|
||||||
|
|
||||||
### Project template
|
### Project template
|
||||||
{%- if cookiecutter.use_mailhog == 'y' and cookiecutter.use_docker == 'n' %}
|
{%- if cookiecutter.use_mailpit == 'y' and cookiecutter.use_docker == 'n' %}
|
||||||
MailHog
|
mailpit
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
{{ cookiecutter.project_slug }}/media/
|
{{ cookiecutter.project_slug }}/media/
|
||||||
|
|
||||||
|
|
|
@ -37,7 +37,7 @@ repos:
|
||||||
args: [--py311-plus]
|
args: [--py311-plus]
|
||||||
|
|
||||||
- repo: https://github.com/psf/black
|
- repo: https://github.com/psf/black
|
||||||
rev: 23.7.0
|
rev: 23.9.1
|
||||||
hooks:
|
hooks:
|
||||||
- id: black
|
- id: black
|
||||||
|
|
||||||
|
|
|
@ -78,37 +78,35 @@ celery -A config.celery_app worker -B -l info
|
||||||
```
|
```
|
||||||
|
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
{%- if cookiecutter.use_mailhog == "y" %}
|
{%- if cookiecutter.use_mailpit == "y" %}
|
||||||
|
|
||||||
### Email Server
|
### Email Server
|
||||||
|
|
||||||
{%- if cookiecutter.use_docker == "y" %}
|
{%- if cookiecutter.use_docker == "y" %}
|
||||||
|
|
||||||
In development, it is often nice to be able to see emails that are being sent from your application. For that reason local SMTP server [MailHog](https://github.com/mailhog/MailHog) with a web interface is available as docker container.
|
In development, it is often nice to be able to see emails that are being sent from your application. For that reason local SMTP server [Mailpit](https://github.com/axllent/mailpit) with a web interface is available as docker container.
|
||||||
|
|
||||||
Container mailhog will start automatically when you will run all docker containers.
|
Container mailpit will start automatically when you will run all docker containers.
|
||||||
Please check [cookiecutter-django Docker documentation](http://cookiecutter-django.readthedocs.io/en/latest/deployment-with-docker.html) for more details how to start all containers.
|
Please check [cookiecutter-django Docker documentation](http://cookiecutter-django.readthedocs.io/en/latest/deployment-with-docker.html) for more details how to start all containers.
|
||||||
|
|
||||||
With MailHog running, to view messages that are sent by your application, open your browser and go to `http://127.0.0.1:8025`
|
With Mailpit running, to view messages that are sent by your application, open your browser and go to `http://127.0.0.1:8025`
|
||||||
{%- else %}
|
{%- else %}
|
||||||
|
|
||||||
In development, it is often nice to be able to see emails that are being sent from your application. If you choose to use [MailHog](https://github.com/mailhog/MailHog) when generating the project a local SMTP server with a web interface will be available.
|
In development, it is often nice to be able to see emails that are being sent from your application. If you choose to use [Mailpit](https://github.com/axllent/mailpit) when generating the project a local SMTP server with a web interface will be available.
|
||||||
|
|
||||||
1. [Download the latest MailHog release](https://github.com/mailhog/MailHog/releases) for your OS.
|
1. [Download the latest Mailpit release](https://github.com/axllent/mailpit/releases) for your OS.
|
||||||
|
|
||||||
2. Rename the build to `MailHog`.
|
2. Copy the binary file to the project root.
|
||||||
|
|
||||||
3. Copy the file to the project root.
|
3. Make it executable:
|
||||||
|
|
||||||
4. Make it executable:
|
$ chmod +x mailpit
|
||||||
|
|
||||||
$ chmod +x MailHog
|
4. Spin up another terminal window and start it there:
|
||||||
|
|
||||||
5. Spin up another terminal window and start it there:
|
./mailpit
|
||||||
|
|
||||||
./MailHog
|
5. Check out <http://127.0.0.1:8025/> to see how it goes.
|
||||||
|
|
||||||
6. Check out <http://127.0.0.1:8025/> to see how it goes.
|
|
||||||
|
|
||||||
Now you have your own mail server running locally, ready to receive whatever you send it.
|
Now you have your own mail server running locally, ready to receive whatever you send it.
|
||||||
|
|
||||||
|
|
|
@ -161,6 +161,7 @@ MIDDLEWARE = [
|
||||||
"django.contrib.auth.middleware.AuthenticationMiddleware",
|
"django.contrib.auth.middleware.AuthenticationMiddleware",
|
||||||
"django.contrib.messages.middleware.MessageMiddleware",
|
"django.contrib.messages.middleware.MessageMiddleware",
|
||||||
"django.middleware.clickjacking.XFrameOptionsMiddleware",
|
"django.middleware.clickjacking.XFrameOptionsMiddleware",
|
||||||
|
"allauth.account.middleware.AccountMiddleware",
|
||||||
]
|
]
|
||||||
|
|
||||||
# STATIC
|
# STATIC
|
||||||
|
|
|
@ -25,12 +25,12 @@ CACHES = {
|
||||||
|
|
||||||
# EMAIL
|
# EMAIL
|
||||||
# ------------------------------------------------------------------------------
|
# ------------------------------------------------------------------------------
|
||||||
{% if cookiecutter.use_mailhog == 'y' and cookiecutter.use_docker == 'y' -%}
|
{% if cookiecutter.use_mailpit == 'y' and cookiecutter.use_docker == 'y' -%}
|
||||||
# https://docs.djangoproject.com/en/dev/ref/settings/#email-host
|
# https://docs.djangoproject.com/en/dev/ref/settings/#email-host
|
||||||
EMAIL_HOST = env("EMAIL_HOST", default="mailhog")
|
EMAIL_HOST = env("EMAIL_HOST", default="mailpit")
|
||||||
# https://docs.djangoproject.com/en/dev/ref/settings/#email-port
|
# https://docs.djangoproject.com/en/dev/ref/settings/#email-port
|
||||||
EMAIL_PORT = 1025
|
EMAIL_PORT = 1025
|
||||||
{%- elif cookiecutter.use_mailhog == 'y' and cookiecutter.use_docker == 'n' -%}
|
{%- elif cookiecutter.use_mailpit == 'y' and cookiecutter.use_docker == 'n' -%}
|
||||||
# https://docs.djangoproject.com/en/dev/ref/settings/#email-host
|
# https://docs.djangoproject.com/en/dev/ref/settings/#email-host
|
||||||
EMAIL_HOST = "localhost"
|
EMAIL_HOST = "localhost"
|
||||||
# https://docs.djangoproject.com/en/dev/ref/settings/#email-port
|
# https://docs.djangoproject.com/en/dev/ref/settings/#email-port
|
||||||
|
|
|
@ -16,8 +16,8 @@ services:
|
||||||
{%- if cookiecutter.use_celery == 'y' %}
|
{%- if cookiecutter.use_celery == 'y' %}
|
||||||
- redis
|
- redis
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
{%- if cookiecutter.use_mailhog == 'y' %}
|
{%- if cookiecutter.use_mailpit == 'y' %}
|
||||||
- mailhog
|
- mailpit
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
volumes:
|
volumes:
|
||||||
- .:/app:z
|
- .:/app:z
|
||||||
|
@ -55,11 +55,11 @@ services:
|
||||||
ports:
|
ports:
|
||||||
- '9000:9000'
|
- '9000:9000'
|
||||||
command: /start-docs
|
command: /start-docs
|
||||||
{%- if cookiecutter.use_mailhog == 'y' %}
|
{%- if cookiecutter.use_mailpit == 'y' %}
|
||||||
|
|
||||||
mailhog:
|
mailpit:
|
||||||
image: mailhog/mailhog:v1.0.0
|
image: axllent/mailpit:v1.8
|
||||||
container_name: {{ cookiecutter.project_slug }}_local_mailhog
|
container_name: {{ cookiecutter.project_slug }}_local_mailpit
|
||||||
ports:
|
ports:
|
||||||
- "8025:8025"
|
- "8025:8025"
|
||||||
|
|
||||||
|
@ -77,8 +77,8 @@ services:
|
||||||
depends_on:
|
depends_on:
|
||||||
- redis
|
- redis
|
||||||
- postgres
|
- postgres
|
||||||
{%- if cookiecutter.use_mailhog == 'y' %}
|
{%- if cookiecutter.use_mailpit == 'y' %}
|
||||||
- mailhog
|
- mailpit
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
ports: []
|
ports: []
|
||||||
command: /start-celeryworker
|
command: /start-celeryworker
|
||||||
|
@ -90,8 +90,8 @@ services:
|
||||||
depends_on:
|
depends_on:
|
||||||
- redis
|
- redis
|
||||||
- postgres
|
- postgres
|
||||||
{%- if cookiecutter.use_mailhog == 'y' %}
|
{%- if cookiecutter.use_mailpit == 'y' %}
|
||||||
- mailhog
|
- mailpit
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
ports: []
|
ports: []
|
||||||
command: /start-celerybeat
|
command: /start-celerybeat
|
||||||
|
|
|
@ -31,7 +31,7 @@ uvicorn[standard]==0.23.2 # https://github.com/encode/uvicorn
|
||||||
django==4.2.5 # pyup: < 5.0 # https://www.djangoproject.com/
|
django==4.2.5 # pyup: < 5.0 # https://www.djangoproject.com/
|
||||||
django-environ==0.11.2 # https://github.com/joke2k/django-environ
|
django-environ==0.11.2 # https://github.com/joke2k/django-environ
|
||||||
django-model-utils==4.3.1 # https://github.com/jazzband/django-model-utils
|
django-model-utils==4.3.1 # https://github.com/jazzband/django-model-utils
|
||||||
django-allauth==0.55.2 # https://github.com/pennersr/django-allauth
|
django-allauth==0.56.1 # https://github.com/pennersr/django-allauth
|
||||||
django-crispy-forms==2.0 # https://github.com/django-crispy-forms/django-crispy-forms
|
django-crispy-forms==2.0 # https://github.com/django-crispy-forms/django-crispy-forms
|
||||||
crispy-bootstrap5==0.7 # https://github.com/django-crispy-forms/crispy-bootstrap5
|
crispy-bootstrap5==0.7 # https://github.com/django-crispy-forms/crispy-bootstrap5
|
||||||
{%- if cookiecutter.frontend_pipeline == 'Django Compressor' %}
|
{%- if cookiecutter.frontend_pipeline == 'Django Compressor' %}
|
||||||
|
|
|
@ -15,7 +15,7 @@ watchfiles==0.20.0 # https://github.com/samuelcolvin/watchfiles
|
||||||
# ------------------------------------------------------------------------------
|
# ------------------------------------------------------------------------------
|
||||||
mypy==1.4.1 # https://github.com/python/mypy
|
mypy==1.4.1 # https://github.com/python/mypy
|
||||||
django-stubs[compatible-mypy]==4.2.3 # https://github.com/typeddjango/django-stubs
|
django-stubs[compatible-mypy]==4.2.3 # https://github.com/typeddjango/django-stubs
|
||||||
pytest==7.4.1 # https://github.com/pytest-dev/pytest
|
pytest==7.4.2 # https://github.com/pytest-dev/pytest
|
||||||
pytest-sugar==0.9.7 # https://github.com/Frozenball/pytest-sugar
|
pytest-sugar==0.9.7 # https://github.com/Frozenball/pytest-sugar
|
||||||
{%- if cookiecutter.use_drf == "y" %}
|
{%- if cookiecutter.use_drf == "y" %}
|
||||||
djangorestframework-stubs[compatible-mypy]==3.14.2 # https://github.com/typeddjango/djangorestframework-stubs
|
djangorestframework-stubs[compatible-mypy]==3.14.2 # https://github.com/typeddjango/djangorestframework-stubs
|
||||||
|
@ -23,15 +23,15 @@ djangorestframework-stubs[compatible-mypy]==3.14.2 # https://github.com/typeddj
|
||||||
|
|
||||||
# Documentation
|
# Documentation
|
||||||
# ------------------------------------------------------------------------------
|
# ------------------------------------------------------------------------------
|
||||||
sphinx==6.2.1 # https://github.com/sphinx-doc/sphinx
|
sphinx==7.2.5 # https://github.com/sphinx-doc/sphinx
|
||||||
sphinx-autobuild==2021.3.14 # https://github.com/GaretJax/sphinx-autobuild
|
sphinx-autobuild==2021.3.14 # https://github.com/GaretJax/sphinx-autobuild
|
||||||
|
|
||||||
# Code quality
|
# Code quality
|
||||||
# ------------------------------------------------------------------------------
|
# ------------------------------------------------------------------------------
|
||||||
flake8==6.1.0 # https://github.com/PyCQA/flake8
|
flake8==6.1.0 # https://github.com/PyCQA/flake8
|
||||||
flake8-isort==6.0.0 # https://github.com/gforcada/flake8-isort
|
flake8-isort==6.0.0 # https://github.com/gforcada/flake8-isort
|
||||||
coverage==7.3.0 # https://github.com/nedbat/coveragepy
|
coverage==7.3.1 # https://github.com/nedbat/coveragepy
|
||||||
black==23.7.0 # https://github.com/psf/black
|
black==23.9.1 # https://github.com/psf/black
|
||||||
djlint==1.32.1 # https://github.com/Riverside-Healthcare/djLint
|
djlint==1.32.1 # https://github.com/Riverside-Healthcare/djLint
|
||||||
pylint-django==2.5.3 # https://github.com/PyCQA/pylint-django
|
pylint-django==2.5.3 # https://github.com/PyCQA/pylint-django
|
||||||
{%- if cookiecutter.use_celery == 'y' %}
|
{%- if cookiecutter.use_celery == 'y' %}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user