mirror of
https://gitea.mueller.network/extern/django-helpdesk.git
synced 2024-11-25 01:13:31 +01:00
Add support for SES
This commit is contained in:
parent
82424cdd5e
commit
8da575c31b
@ -9,7 +9,7 @@ To install run `setup.sh` and then `docker-compose up` in this directory.
|
|||||||
To create an admin user exec into the newly created container
|
To create an admin user exec into the newly created container
|
||||||
|
|
||||||
docker ps
|
docker ps
|
||||||
docker exec -it standalone-web-1 bash
|
docker exec -it standalone-django-helpdesk-1 bash
|
||||||
|
|
||||||
In the container cd to `/opt/django-helpdesk/standalone` and run
|
In the container cd to `/opt/django-helpdesk/standalone` and run
|
||||||
|
|
||||||
@ -38,3 +38,25 @@ You can change the logo at the top left of the helpdesk by bindmounting a file
|
|||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Here is an example `local_settings` file for using AWS SES for sending emails:
|
||||||
|
|
||||||
|
```
|
||||||
|
import os
|
||||||
|
|
||||||
|
DEFAULT_FROM_EMAIL = "support@bitswan.space"
|
||||||
|
SERVER_EMAIL = "support@bitswan.space"
|
||||||
|
AWS_ACCESS_KEY_ID = os.environ.get("AWS_ACCESS_KEY_ID")
|
||||||
|
EMAIL_BACKEND = "django_ses.SESBackend"
|
||||||
|
AWS_SES_REGION_NAME = "eu-west-1"
|
||||||
|
AWS_SES_REGION_ENDPOINT = "email.eu-west-1.amazonaws.com"
|
||||||
|
AWS_SECRET_ACCESS_KEY = os.environ.get("AWS_SECRET_ACCESS_KEY")
|
||||||
|
```
|
||||||
|
|
||||||
|
In this case you'll also have to bindmout a file to `/opt/extra-dependencies.txt` with the contents:
|
||||||
|
|
||||||
|
```
|
||||||
|
django-ses
|
||||||
|
```
|
||||||
|
|
||||||
|
You would of course also have to edit docker.env to add your secrets.
|
||||||
|
@ -1,4 +1,9 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
# Install extra deps from /opt/extra-deps.txt if it exists
|
||||||
|
if [ -f /opt/extra-dependencies.txt ]; then
|
||||||
|
pip install -r /opt/extra-dependencies.txt
|
||||||
|
fi
|
||||||
|
|
||||||
cd /opt/django-helpdesk/standalone/
|
cd /opt/django-helpdesk/standalone/
|
||||||
if python manage.py showmigrations | grep '\[ \]\|^[a-z]' | grep '[ ]' -B 1; then
|
if python manage.py showmigrations | grep '\[ \]\|^[a-z]' | grep '[ ]' -B 1; then
|
||||||
python manage.py migrate --noinput # Apply database migrations
|
python manage.py migrate --noinput # Apply database migrations
|
||||||
|
Loading…
Reference in New Issue
Block a user