Skip to content

Commit

Permalink
Add documentation for the configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
penguineer committed Nov 2, 2024
1 parent 4141f60 commit 17dea11
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
9 changes: 9 additions & 0 deletions .env.template
Original file line number Diff line number Diff line change
@@ -1 +1,10 @@
PORT=8080

MQTT_BROKER=mqtt.local
MQTT_PORT=1883

MQTT_LEVER_STATE_TOPIC=
MQTT_DOOR_EVENTS_TOPIC=
MQTT_SPACESTATUS_ISOPEN_TOPIC=
MQTT_SPACESTATUS_LASTCHANGE_TOPIC=
MQTT_TRAFFIC_LIGHT_TOPIC=
9 changes: 8 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,14 @@ run independently.
Configuration is done using environment variables:

* `PORT`: Target port when used with docker-compose (default `8080`)

* `MQTT_BROKER`: MQTT broker server (default `mqtt`)
* `MQTT_PORT`: MQTT broker port (default `1883`)
* `MQTT_LEVER_STATE_TOPIC`: MQTT topic to listen for lever state messages (default `lever`)
* `MQTT_DOOR_EVENTS_TOPIC`: MQTT topic to listen for door events (default `door`)
* `MQTT_SPACESTATUS_ISOPEN_TOPIC`: MQTT topic to publish space status (default `isOpen`)
* `MQTT_SPACESTATUS_LASTCHANGE_TOPIC`: MQTT topic to publish last change messages (default `lastchange`)
* `MQTT_TRAFFIC_LIGHT_TOPIC`: MQTT topic to publish traffic light status (default `trafficlight`)
*
### Run with Docker

```bash
Expand Down

0 comments on commit 17dea11

Please sign in to comment.