Installation of Tracardi is quite straight forward. The easiest way to run Tracardi is to run it as a docker container.
Tracardi need elasticsearch as its backend. So, first thing we will do is installation of elastic search.
Please pull and run elasticsearch single node docker. You can do it with this command.
docker run -p 9200:9200 -p 9300:9300 -e "discovery.type=single-node" -d docker.elastic.co/elasticsearch/elasticsearch:7.13.2
Note: Running one instance of elasticsaerch is not a production solution. For production purposes, it is necessary to run the elasticearch cluster. Please refer to our documentation for more details.
Tracardi depends also on Redis. If you use features as destinations, import, or synchronized events then you certainly will need a redis instance.
docker run -p 6379:6379 -d redis
Now it is time to run TRACARDI backend. Type:
docker run -d -p 8686:80 -e ELASTIC_HOST=http://<your-laptop-ip>:9200 -e REDIS_HOST=redis://<your-laptop-ip>:6379 tracardi/tracardi-api:0.8.0
Tracardi must connect to elasticsearch. To do that you have to set ELASTIC_HOST variable to reference your laptop’s or server IP.
Warning: Notice that when type ELASTIC_HOST=
http://localhost:9200 you try to connect to Elastic on localhost. This means that you’re connecting to the docker itself as localhost means local in docker. Obviously elastic is not there, so Tracardi will never connect. Pass external ip for elastic. This may be your laptop IP if you are running Tracardi locally.
Start Tracardi GUI
Last part of Tracardi platform is Graphical User Interface. Run the following command to start GUI
docker run -p 8787:80 -e API_URL=//127.0.0.1:8686 tracardi/tracardi-gui:0.8.0
Notice that the
API_URL is set to
localhost. If the API is located somewhere else replace localhost with the ip pointing to Tracardi backend API. For our local setup localhost is just fine.
Type http://127.0.0.1:8787 in your browser and follow the instructions to set-up Tracardi. Enjoy.