Deployment
This guide walks you through deploying Colander on a dedicated server.
Colander’s official Docker image is available on GitHub. The stack we provide includes the Watchtower service, which automatically updates the deployed version of Colander.
Requirements
We recommend using a dedicated server with at least:
- 4 cores
- 4GB of RAM
- 500GB of storage space
We recommend installing Debian, as it’s the operating system we’re most familiar with. We can guide you through the entire process, from installation to maintenance and debugging.
Your server must have a public IP address as well as a domain name.
Download Colander package
First, dowload the latest Colander deployment package from Github.
Decompress the package on your server.
Configure the server
Next, configure the deployment by editing the file .envs/.tpl/.base
. Set the following variables according to your production environment:
ACME_EMAIL
: Email address for to the TLS certificateADMIN_NAME
: Administrator’s full nameADMIN_EMAIL
: Email address for crash and error notificationsROOT_DOMAIN
: Domain name pointing to your serverDJANGO_DEFAULT_FROM_EMAIL
: Email address used for sending emailsEMAIL_HOST
: Host for sending email (can be the SMTP server of your email provider)EMAIL_HOST_USER
: Username for the SMTP serverEMAIL_HOST_PASSWORD
: Password for the SMTP serverEMAIL_PORT
: Port for the SMTP serverEMAIL_USE_TLS
:True
if the SMTP server uses TLS,False
otherwiseEMAIL_USE_SSL
:True
if the SMTP server uses SSL,False
otherwise
For detailed email configuration, refer to the Django documentation.
Generete configuration
Once configured, generate the entire stack configuration by running:
This script creates multiple files containing environment variables for different services.
Start the stack
Now, use docker compose
to start the Colander stack:
This starts the Colander services. You can view the logs with:
Access Colander
Use your web browser to access Colander at the configured domain name.
Admin user
Create admin users for both Colander and Threatr by using the following commands:
Follow the instructions to create the accounts.
Backup
Remember to backup your credentials and the .envs
folder.
Load Threatr data
Threatr includes predefined entity types. To load them, run:
Connect Colander to Threatr
To connect Colander to Threatr, follow these steps:
In the Threatr administration panel, create a regular user in the menu Users menu and an API key for this user in the menu Tokens.
In the administration panel of Colander, via the menu Backend credentials, create a new entry with
threatr
as backend identifier and for the credentials field, set
Administration panel URLs
Note that the administration panels are accessible at random URLs:
- for Colander:
https://${COLANDER_FQDN}/${DJANGO_ADMIN_URL}
with the variables set in.envs/.production/.base
and.envs/.production/.colander
- for Threatr:
https://${THREATR_FQDN}/${DJANGO_ADMIN_URL}
with the variables set in.envs/.production/.base
and.envs/.production/.threatr
Connect Threatr to 3rd-party vendors
In the Threatr administration panel, create new entries for the 3rd-party vendors in the Vendor Credentials menu.
Did you know?
You can add multiple API keys for a same vendor, Threatr will do a round-robin on them. To do so, add multiple Vendor Credentials for the same vendor identifier.
Development environment setup
Here’s how to set up Colander for development:
Clone the Colander repository. Build and start the Colander stack using Docker Compose (or Podman). The local.yml
provides the entire stack you need.
Then, you should be able to access Colander at http://localhost:8000.
To stop the development envirnoment, use: