Skip to content

yaroslaff/sensor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Okerr remote network sensor

Install

PIPX_HOME=/opt/pipx PIPX_BIN_DIR=/usr/local/bin install git+https://github.com/yaroslaff/sensor/

PIPX_HOME=/opt/pipx PIPX_BIN_DIR=/usr/local/bin pipx reinstall okerrsensor

or (old way):

pip3 install git+https://github.com/yaroslaff/sensor/

configure /etc/okerrclient.conf

Prepare env config file:

root@deb10:~# cat /etc/okerr/env/sensor  
SENSOR_NAME=deb10@nsk.ru
RMQ_USER=okerr-rabbit-user
RMQ_PASS=okerr-rabbit-secret-password
RMQ_VHOST=okerr
RMQ_HOST=rabbitmq.example.com

Run from shell

$ cp .env-example .env
$ vim .env # Adjust settings
$ . .env
$ sudo sensor.py 
20191228 01:09:35 started sensor deb10@nsk.ru

Install as systemd service

mkdir /var/log/okerr

cp /usr/local/okerrsensor/okerr-sensor.service /etc/systemd/system/
systemctl daemon-reload
systemctl enable okerr-sensor
systemctl start okerr-sensor

Run on low-memory machines

Use --oneprocess option, or set env variable SENSOR_ONEPROCESS to any non-empty value (e.g. in /etc/okerr/env/sensor)

Build dist from source

git clone git@github.com:yaroslaff/sensor.git
python3 setup.py bdist_wheel

Other okerr resources

Releases

No releases published

Packages

No packages published

Languages