pipenv
using python -m pip install pipenv
python -m pipenv install
to install the prerequisites.config.ini
and adjust the settings to your use-case.Run python -m pipenv run python main.py
to start the application.
citizentocot.service
to the correct working directory, user, and shell script directory.cp citizentocot.service /etc/systemd/system/
sudo systemctl daemon-reload
sudo systemctl enable citizentocot
(if you want to run it at boot, otherwise skip this step)sudo systemctl start citizentocot
to start the serviceThis 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