Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
user_config_override.h - user configuration overrides user_config.h for Sonoff-Tasmota | |
Copyright (C) 2018 Theo Arends | |
This program is free software: you can redistribute it and/or modify | |
it under the terms of the GNU General Public License as published by | |
the Free Software Foundation, either version 3 of the License, or | |
(at your option) any later version. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Ensure you replace <mongo-admin> and <password> with your mongodb credentials | |
# Variables | |
########################### | |
CONTAINER="mongodb" | |
DATETIME=$(date +"%Y_%m_%d") | |
BACKUP_PATH="/var/docker/backup" | |
DROPBOX_UPLOADER_CONFIG_PATH="/var/docker/dropbox-uploader" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Hardening as-per https://gist.github.com/plentz/6737338 | |
server_tokens off; | |
# Expires map | |
map $sent_http_content_type $expires { | |
default off; | |
text/html epoch; | |
text/css max; | |
application/javascript max; | |
~image/ max; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/lib/mosquitto_internal.h b/lib/mosquitto_internal.h | |
index 4b4cf85..700bbb0 100644 | |
--- a/lib/mosquitto_internal.h | |
+++ b/lib/mosquitto_internal.h | |
@@ -25,6 +25,9 @@ Contributors: | |
#ifdef WITH_TLS | |
# include <openssl/ssl.h> | |
+# if OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER) | |
+# define HAVE_OPENSSL_OPAQUE_STRUCTS |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -e | |
exec "$@" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Place your local configuration in /mosquitto/config/conf.d/ | |
port 1883 | |
pid_file /var/run/mosquitto.pid | |
persistence true | |
persistence_location /mosquitto/data/ | |
user mosquitto |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mongo mongodb://localhost/users --authenticationDatabase admin -u '<mongo-admin-user>' -p '<mongo-admin-password>' --eval ' | |
db.createUser({ | |
user: "<web-app-user>", | |
pwd: "<web-app-password>", | |
roles: [{ | |
role: "readWrite", | |
db: "users" | |
}] | |
})' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
auth_plugin /usr/local/lib/auth-plug.so | |
auth_opt_backends mongo | |
auth_opt_mongo_uri mongodb://<user>:<password>@<mongo-server>:27017 | |
auth_opt_mongo_database users | |
auth_opt_mongo_user_username_prop username | |
auth_opt_mongo_user_password_prop mqttPass | |
auth_opt_mongo_user_superuser_prop superuser | |
auth_opt_mongo_user_coll accounts | |
auth_opt_mongo_topiclist_coll topics | |
auth_opt_mongo_user_topiclist_fk_prop topics |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# mongod.conf | |
# for documentation of all options, see: | |
# http://docs.mongodb.org/manual/reference/configuration-options/ | |
# Where and how to store data. | |
storage: | |
dbPath: /var/lib/mongodb | |
journal: | |
enabled: true |