MQTT File Uploader is a simple Cross-platform .NET Core application that watches local directories for changes and uploads new or modified files to an MQTT broker.
- Watch multiple local directory for new or modified files
- Upload files to an MQTT broker
- Support MQTT versions 5.0, 3.1.1, and 3.1
- Compress files with GZip before uploading
- Support for disabling
Created
,Changed
, andDeleted
events - Configuration settings can be specified in a TOML file
- SSL/TLS encryption support
- .NET Core 7 or later
- An MQTT broker
- Clone the repository or download the source code
- Build the project with
dotnet build
- Update the
config.toml
file with your MQTT broker settings and SSL/TLS options - Run the application with
dotnet run
The config.toml
file contains the following options:
directoryPaths
: local directories to watch for changesbrokerHostname
: hostname of the MQTT broker to upload files tobrokerPort
: port number of the MQTT broker to upload files tobrokerUsername
: username to use to connect to the MQTT broker (optional)brokerPassword
: password to use to connect to the MQTT broker (optional)topic
: MQTT topic to publish files tocompress
: Whether to compress files with GZip before uploadingcreatedEventEnabled
: Whether to upload files that are created in the watched directorychangedEventEnabled
: Whether to upload files that are modified in the watched directorydeletedEventEnabled
: Whether to delete files on the MQTT broker when they are deleted from the watched directorytlsEnabled
: Whether to use SSL/TLS encryption for the connection
This project is licensed under the MIT License - see the LICENSE.md file for details.