A useful Salt Event returner for publishing messages to MQTT or AWS IoT
Project description
mqtt_return
A useful Salt Event returner for publishing messages to MQTT or AWS IoT
Quickstart
To get started with your new project:
# Create a new venv
python3 -m venv env --prompt mqtt_return
source env/bin/activate
# On mac, you may need to upgrade pip
python -m pip install --upgrade pip
# On WSL or some flavors of linux you may need to install the `enchant`
# library in order to build the docs
sudo apt-get install -y enchant
# Install extension + test/dev/doc dependencies into your environment
python -m pip install -e .[tests,dev,docs]
# Run tests!
python -m nox -e tests-3
# skip requirements install for next time
export SKIP_REQUIREMENTS_INSTALL=1
# Build the docs, serve, and view in your web browser:
python -m nox -e docs && (cd docs/_build/html; python -m webbrowser localhost:8000; python -m http.server; cd -)
# Run the example function
salt-call --local mqtt_return.example_function text="Happy Hacking!"
Configuration
For publishing to a standard MQTT broker
event_return: [mqtt]
returner.mqtt.output: mqtt
returner.mqtt.endpoint: mqtt
returner.mqtt.port: 1883
returner.mqtt.topic_prefix: "example/prefix"
For publishing to AWS IoT Core MQTT broker
event_return: [mqtt]
returner.mqtt.output: awsiot
returner.mqtt.endpoint: example.iot.amazonaws.com
returner.mqtt.topic_prefix: "example/prefix"
returner.mqtt.aws_access_key_id: "aaaaa"
returner.mqtt.aws_secret_access_key: "aaaaa"
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
saltext.mqtt_return-0.1a2.tar.gz
(27.6 kB
view hashes)
Built Distribution
Close
Hashes for saltext.mqtt_return-0.1a2.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | bd01be7fc5df39dd7c1b5499d4a86c2409ce0a3c4c700588e614c79ceacf0862 |
|
MD5 | 784865ff24ce6a8203c80bcae38c7a2f |
|
BLAKE2b-256 | 1ec2e90117a469100906af79d19179a8e6d598fce5d020446042b8fef230f273 |
Close
Hashes for saltext.mqtt_return-0.1a2-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8e5626e6acc340fc3c7e6d029099be8e467f97926f4bcc4841c1d7ed28186562 |
|
MD5 | a88ca2c66629dc209d3cc8e79e9ceee3 |
|
BLAKE2b-256 | c15a95a7b8639c2f2376bdaea5e030915261bbedef8d078ecdc1634ea6663f25 |