Docker Compose
Deploy Tracecat using a Docker Compose template.
Prerequisites
Verify Prerequisites
To verify that Docker Compose and Docker are installed on the machine where you plan to install Tracecat, run the following commands.
Download Configuration Files
If you’re deploying Tracecat into an external instance (e.g. AWS EC2, GCP Compute Engine, Azure VM),
please note that you’ll have to set PUBLIC_APP_URL
and PUBLIC_API_URL
in the .env
file
to the IP address or host you are accessing Tracecat from.
For example, if you are port forwarding Tracecat from http://localhost
(port 80) inside AWS EC2
to http://localhost:8080
on your local machine, you must set PUBLIC_APP_URL
to http://localhost:8080
and PUBLIC_API_URL
to http://localhost:8080/api/
.
You can set these options when running the env.sh
configuration script.
Tracecat requires a set of environment variables and credentials stored in .env
file to run.
We created a helpful shell script to generate the .env
file.
Use the commands listed below to download the required configuration files
(env.sh
, .env.example
) and generate your own .env
file.
You should see the following instructions after executing env.sh
.
You’ll be prompted to input the following:
y
(yes to production mode)localhost
(default host)n
(no to postgres SSL mode).
Otherwise, if you’re deploying Tracecat into an external / Cloud VM, input:
y
(yes to production mode)<host-where-tracecat-is-exposed>
(e.g.localhost:8080
)n
(no to postgres SSL mode).
Download Caddyfile
Tracecat uses Caddy as a reverse proxy.
You’ll need to download the following Caddyfile
to configure this service.
Download Docker Compose File
Start Tracecat
Run the command below to start Tracecat and all related services.
Make sure your docker-compose.yml
and generated .env
files are in the same directory.
Your Tracecat instance should now be running on http://localhost
.
To access the Tracecat GUI, visit http://localhost
.
Tracecat comes with a REST API, you can visit the live API docs at
http://localhost/api/docs
.
Login
Find out how to configure authentication in Tracecat. View docs.
For each new Tracecat deployment, the admin superuser role is assigned to the first user who logs into the Tracecat instance. This user owns the organization and has admin rights to every workspace in the Tracecat deployment.
To proceed, sign up and create an account with a strong and secure password.
Next Steps
- Log into Tracecat and build your first playbook. View quickstart.
- Tracecat comes with basic (email + password) authentication. Find out how to configure other authentication methods. View docs.
- Read inline comments in the generated
.env
file to better understand Tracecat’s configurations. View.env.example
file