Environment variables¶
Set them in deploy/production.env. The full list, with defaults, is in
deploy/production.env.example and
.env.example.
Variable |
Default |
Purpose |
|---|---|---|
|
(none: required) |
Host names HouseCairn answers to, comma-separated. |
|
(none) |
|
|
|
|
|
|
Addresses or networks of that proxy, comma-separated: only their forwarding headers count (see Reverse proxy). |
|
generated in |
Set it only to manage the key yourself. |
|
SQLite in |
For example |
|
|
Time zone of the instance. |
|
|
Allow local sign-up from the web page; needs email. See Open sign-up. |
|
|
Work of the anti-robot check of sign-up, from 8 to 24 bits. |
|
(none) |
Comma-separated domains that may, or may not, sign up. |
|
|
Whether an address must be verified before sign-in. |
|
|
Cache of the rate-limit counters; |
|
(none) |
Single sign-on through any OpenID Connect provider. |
|
|
Who may get an account through single sign-on. |
|
(none) |
Outgoing mail server (SMTP); email is off while it is empty. See Email. |
|
|
TLS from the first byte; seconds to wait for the server. See Email. |
|
(none: set it in production) |
Public address of the instance, such as |
|
|
Days an invitation link stays valid, from 1 to 90. |
|
|
Address of this documentation, used by the help link of each screen. |
|
|
Web server processes. |
|
|
Task worker processes. |
|
|
Seconds given to both to stop; keep it below Compose’s |
|
|
Port inside the container. |
|
|
Application log level; logs go to the container output. |
Set inside the image, not to be changed: HOUSECAIRN_DATA_DIR=/data,
STATIC_ROOT=/app/static, DJANGO_SETTINGS_MODULE=housecairn.settings.
Email¶
HouseCairn sends email for invitations, address verification, password reset
and security alerts. Set EMAIL_HOST to your SMTP server to turn it on, with
EMAIL_PORT (587), EMAIL_HOST_USER, EMAIL_HOST_PASSWORD,
EMAIL_USE_TLS (true), EMAIL_USE_SSL, EMAIL_TIMEOUT and
DEFAULT_FROM_EMAIL. All of it is on the Email page, with what
becomes of the features that need a mailbox when there is none.
Links in emails point to HOUSECAIRN_SITE_URL when it is set. Set it in
production. Without it, a link takes the host of the request that triggered
it: ALLOWED_HOSTS limits that to the names the instance answers to, but a
proxy that lets a request choose its host, or several names in
ALLOWED_HOSTS, can make a link point where you did not intend.
manage.py check --deploy reports EMAIL_HOST set without
HOUSECAIRN_SITE_URL.
PostgreSQL¶
SQLite is the default and is enough for a household. To use PostgreSQL, the
example compose.yaml has a postgres service, started only with the
postgres profile:
cp deploy/postgres.env.example deploy/postgres.envand set a password.In
deploy/production.env, setDATABASE_URL=postgres://housecairn:<password>@postgres:5432/housecairn.Uncomment
depends_onin thehousecairnservice, thendocker compose --profile postgres up -d.
An existing PostgreSQL server works too: set DATABASE_URL to it.