- Install
pipenv
usingpython -m pip install pipenv
- Run
python -m pipenv install
to install the prerequisites. - Create a
config.ini
and adjust the settings to your use-case.
Run python -m pipenv run python main.py
to start the application.
- Modify
citizentocot.service
to the correct working directory, user, and shell script directory. - Copy it to the right directory using
cp citizentocot.service /etc/systemd/system/
- Run
sudo systemctl daemon-reload
- Run
sudo systemctl enable citizentocot
(if you want to run it at boot, otherwise skip this step) - Run
sudo systemctl start citizentocot
to start the service
This config connects to a TAK server instance via TLS (using a self-signed cert), pulls data and pushes CoT events every 30 minutes.
config.ini
[citizentocot]
COT_URL = tls://XX.XX.XX.XX:8089
PYTAK_TLS_CLIENT_CERT = private_key.pem
PYTAK_TLS_CLIENT_KEY = private_key.pem
PYTAK_TLS_DONT_VERIFY = true
CITIZEN_API_URL = https://citizen.com/api/incident/trending?lowerLatitude=XX&lowerLongitude=XX&upperLatitude=XX&upperLongitude=XX&fullResponse=true&limit=200
POLL_INTERVAL = 1800