settings(minor): use cached_db for session, use localhost as domain
This commit is contained in:
parent
fff99f0e3d
commit
3b7e47dbe2
|
@ -3,6 +3,7 @@
|
||||||
## Quick instance
|
## Quick instance
|
||||||
|
|
||||||
```
|
```
|
||||||
|
export PASSBOOK_DOMAIN=domain.tld
|
||||||
docker-compose pull
|
docker-compose pull
|
||||||
docker-compose up -d
|
docker-compose up -d
|
||||||
docker-compose exec server ./manage.py migrate
|
docker-compose exec server ./manage.py migrate
|
||||||
|
|
|
@ -28,6 +28,7 @@ services:
|
||||||
- uwsgi
|
- uwsgi
|
||||||
- uwsgi.ini
|
- uwsgi.ini
|
||||||
environment:
|
environment:
|
||||||
|
- PASSBOOK_DOMAIN=${PASSBOOK_DOMAIN}
|
||||||
- PASSBOOK_REDIS__HOST=redis
|
- PASSBOOK_REDIS__HOST=redis
|
||||||
- PASSBOOK_POSTGRESQL__HOST=postgresql
|
- PASSBOOK_POSTGRESQL__HOST=postgresql
|
||||||
- PASSBOOK_POSTGRESQL__PASSWORD=${PG_PASS:-thisisnotagoodpassword}
|
- PASSBOOK_POSTGRESQL__PASSWORD=${PG_PASS:-thisisnotagoodpassword}
|
||||||
|
@ -53,6 +54,7 @@ services:
|
||||||
labels:
|
labels:
|
||||||
- traefik.enable=false
|
- traefik.enable=false
|
||||||
environment:
|
environment:
|
||||||
|
- PASSBOOK_DOMAIN=${PASSBOOK_DOMAIN}
|
||||||
- PASSBOOK_REDIS__HOST=redis
|
- PASSBOOK_REDIS__HOST=redis
|
||||||
- PASSBOOK_POSTGRESQL__HOST=postgresql
|
- PASSBOOK_POSTGRESQL__HOST=postgresql
|
||||||
- PASSBOOK_POSTGRESQL__PASSWORD=${PG_PASS:-thisisnotagoodpassword}
|
- PASSBOOK_POSTGRESQL__PASSWORD=${PG_PASS:-thisisnotagoodpassword}
|
||||||
|
|
|
@ -16,7 +16,7 @@ debug: false
|
||||||
# Error reporting, sends stacktrace to sentry.services.beryju.org
|
# Error reporting, sends stacktrace to sentry.services.beryju.org
|
||||||
error_report_enabled: true
|
error_report_enabled: true
|
||||||
|
|
||||||
domain: passbook.local
|
domain: localhost
|
||||||
|
|
||||||
passbook:
|
passbook:
|
||||||
sign_up:
|
sign_up:
|
||||||
|
|
|
@ -117,7 +117,7 @@ CACHES = {
|
||||||
}
|
}
|
||||||
DJANGO_REDIS_IGNORE_EXCEPTIONS = True
|
DJANGO_REDIS_IGNORE_EXCEPTIONS = True
|
||||||
DJANGO_REDIS_LOG_IGNORED_EXCEPTIONS = True
|
DJANGO_REDIS_LOG_IGNORED_EXCEPTIONS = True
|
||||||
SESSION_ENGINE = "django.contrib.sessions.backends.cache"
|
SESSION_ENGINE = "django.contrib.sessions.backends.cached_db"
|
||||||
SESSION_CACHE_ALIAS = "default"
|
SESSION_CACHE_ALIAS = "default"
|
||||||
|
|
||||||
MIDDLEWARE = [
|
MIDDLEWARE = [
|
||||||
|
|
Reference in New Issue