Skip to main content

Okerr remote network sensor

Install

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

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

# or simpler
pipx install git+https://github.com/yaroslaff/sensor/

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

SENSOR_IP=1.2.3.4

## only for local debugging
#SENSOR_PEM=.local/ssl/client.pem
# SENSOR_CAPEM=.local/ssl/ca.pem
export SENSOR_NAME RMQ_HOST RMQ_VHOST  RMQ_USER RMQ_PASS SENSOR_PEM SENSOR_CAPEM

Run from shell

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

Specify check from CLI:

sensor --manual httpstatus url=https://cat.okerr.com/ status=200 options=addr=88.214.35.64

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

Metadata

Release files for okerrsensor 0.0.77

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for okerrsensor 0.0.77
File Size Uploaded Provenance
okerrsensor-0.0.77.tar.gz 19.8 kB Without provenance Details

Release files / okerrsensor-0.0.77.tar.gz

Download URL okerrsensor-0.0.77.tar.gz
Size 19.8 kB
Tags Source
SHA-256 checksum
How to use checksums
3830df0ea66ccc2da89fd6c78ed68f6f5456d445b964758ef34fb296c2f3ef7e
BLAKE2b-256 checksum
How to use checksums
680fef210563da96d41f1ec8b5604f8c6a14bd62d3bff73fb2cb5dc41c7e5244
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via python-httpx/0.28.1

Security for okerrsensor 0.0.77

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page