OpenCTI Docker Deployment
Informational
Install Docker Compose
$ sudo apt-get install docker-compose
Clone the repository
$ git clone https://github.com/OpenCTI-Platform/docker.git opencti-docker
$ cd opencti-docker
Configure the environment settings
Before running the docker-compose command, settings must be configured. Copy the sample settings file and change it accordingly to your needs.
$ vi .env
OPENCTI_ADMIN_EMAIL=admin@opencti.io
OPENCTI_ADMIN_PASSWORD=changeme
OPENCTI_ADMIN_TOKEN=ChangeMe_UUIDv4
OPENCTI_BASE_URL=http://localhost:8080
MINIO_ROOT_USER=opencti
MINIO_ROOT_PASSWORD=changeme
RABBITMQ_DEFAULT_USER=opencti
RABBITMQ_DEFAULT_PASS=changeme
CONNECTOR_EXPORT_FILE_STIX_ID=dd817c8b-abae-460a-9ebc-97b1551e70e6
CONNECTOR_EXPORT_FILE_CSV_ID=7ba187fb-fde8-4063-92b5-c3da34060dd7
CONNECTOR_EXPORT_FILE_TXT_ID=ca715d9c-bd64-4351-91db-33a8d728a58b
CONNECTOR_IMPORT_FILE_STIX_ID=72327164-0b35-482b-b5d6-a5a3f76b845f
CONNECTOR_IMPORT_DOCUMENT_ID=c3970f8a-ce4b-4497-a381-20b7256f56f0
SMTP_HOSTNAME=localhost
ELASTIC_MEMORY_SIZE=4G
Important: you must change OPENCTI_ADMIN_TOKEN to a valid UUIDv4 token.
In case you need to generate a UUID, use the following command:
$ cat /proc/sys/kernel/random/uuid
Memory management settings
As OpenCTI has a dependency on ElasticSearch, you have to set the vm.max_map_count before running the containers.
$ sudo sysctl -w vm.max_map_count=1048575
To make this parameter persistent, add the following to the end of your /etc/sysctl.conf:
$ vm.max_map_count=1048575
Run OpenCTI
The following commands will allow you to run OpenCTI in your local instance using docker.
Load the environment setttings:
set -a ; source .env
Single node Docker with Single ElasticSearch Node
Run docker-compose in detached (-d) mode:
$ sudo docker-compose up -d
How to update your docker instances
For single node Docker
$ sudo docker-compose stop
$ sudo docker-compose pull
$ sudo docker-compose up -d