home-automation/docker
KemoNine e2a4616c96 Add mosquitto notes to docker readme 2019-05-14 15:29:06 +00:00
..
README.md Add mosquitto notes to docker readme 2019-05-14 15:29:06 +00:00
mosquitto.conf Add mosquitto MQTT broker basics 2019-05-14 15:06:49 +00:00
run-appdaemon.sh Fixup root URL of HADashboard ; cleanup Hello app that was added initially 2019-05-04 19:17:41 +00:00
run-home-assistant.sh Initial HADashboard bring up 2019-05-04 18:32:16 +00:00
run-mosquitto.sh Add mosquitto MQTT broker basics 2019-05-14 15:06:49 +00:00

README.md

Docker

Various run scripts for deploying Home-Automation.io on arm boards. Raspberry Pi and others are supported.

Mosquito Setup

Users


docker exec -it mosquitto mosquitto_passwd -c /mosquitto/config/passwd.db user
docker exec -it mosquitto mosquitto_passwd /mosquitto/config/passwd.db user

SSL

Prep / Pre-Reqs


mkdir /var/mosquitto/config/ssl
cd /var/mosquitto/config/ssl

Server SSL Setup


# Generate a certificate authority certificate and key.
openssl req -new -x509 -days 36500 -extensions v3_ca -keyout ca.key -out ca.crt
# Generate a server key without encryption.
openssl genrsa -out server.key 4096
# Generate a certificate signing request to send to the CA.
#    When prompted for the CN (Common Name), please enter either your server (or broker) hostname or domain name.
openssl req -out server.csr -key server.key -new
# Send the CSR to the CA, or sign it with your CA key:
openssl x509 -req -in server.csr -CA ca.crt -CAkey ca.key -CAcreateserial -out server.crt -days 3650

Client SSL Setup


# Generate a client key.
openssl genrsa -des3 -out client.key 4096
# Generate a certificate signing request to send to the CA.
openssl req -out client.csr -key client.key -new
# Send the CSR to the CA, or sign it with your CA key:
openssl x509 -req -in client.csr -CA ca.crt -CAkey ca.key -CAcreateserial -out client.crt -days <duration>