updating configuration
This commit is contained in:
+1
-1
@@ -3,7 +3,7 @@ python:
|
|||||||
- '3.5'
|
- '3.5'
|
||||||
install:
|
install:
|
||||||
- 'pip3 install homeassistant'
|
- 'pip3 install homeassistant'
|
||||||
- 'mv secrets.yaml.sample secrets.yaml'
|
- 'mv hass/settings/secrets.yaml.sample hass/settings/secrets.yaml'
|
||||||
script:
|
script:
|
||||||
- 'cd hass/settings/ && hass -c . --script check_config | tee check.output'
|
- 'cd hass/settings/ && hass -c . --script check_config | tee check.output'
|
||||||
- '! less check.output | grep -q ERROR'
|
- '! less check.output | grep -q ERROR'
|
||||||
|
|||||||
+11
-3
@@ -73,14 +73,21 @@ services:
|
|||||||
links:
|
links:
|
||||||
- "hass"
|
- "hass"
|
||||||
- "appdaemon"
|
- "appdaemon"
|
||||||
|
env_file: ./nginx/settings/nginx.env
|
||||||
volumes:
|
volumes:
|
||||||
- /srv/homeassistant/hosts.txt:/etc/hosts:ro
|
- ./hass/settings/hosts.txt:/etc/hosts:ro
|
||||||
volumes:
|
- ./nginx/settings/site-confs:/etc/nginx/conf.d.source:ro
|
||||||
- /srv/ssl:/config/keys
|
- /srv/ssl:/config/keys
|
||||||
- ./nginx-config/site-confs:/etc/nginx/conf.d
|
|
||||||
ports:
|
ports:
|
||||||
- "80:80"
|
- "80:80"
|
||||||
- "443:443"
|
- "443:443"
|
||||||
|
command: |
|
||||||
|
/bin/bash -c "cp -R /etc/nginx/conf.d.source/* /etc/nginx/conf.d && \
|
||||||
|
sed -i \"s/%DOMAIN%/$$HASS_DOMAIN/g\" /etc/nginx/conf.d/*.conf && \
|
||||||
|
sed -i \"s/%PASS%/$$HASS_PASSWORD/g\" /etc/nginx/conf.d/*.conf && \
|
||||||
|
sed -i \"s/%SERVER_IP%/$$SERVER_IP/g\" /etc/nginx/conf.d/*.conf && \
|
||||||
|
cat /etc/nginx/conf.d/*.conf && \
|
||||||
|
nginx -g 'daemon off;'"
|
||||||
logging:
|
logging:
|
||||||
driver: json-file
|
driver: json-file
|
||||||
options:
|
options:
|
||||||
@@ -117,6 +124,7 @@ services:
|
|||||||
driver: json-file
|
driver: json-file
|
||||||
options:
|
options:
|
||||||
max-size: 50m
|
max-size: 50m
|
||||||
|
|
||||||
###########################
|
###########################
|
||||||
# GRAFANA #
|
# GRAFANA #
|
||||||
###########################
|
###########################
|
||||||
|
|||||||
@@ -1,23 +0,0 @@
|
|||||||
server {
|
|
||||||
listen 80 default_server;
|
|
||||||
listen 443 default ssl;
|
|
||||||
|
|
||||||
root /config/www;
|
|
||||||
index index.html index.htm index.php;
|
|
||||||
|
|
||||||
server_name _;
|
|
||||||
|
|
||||||
ssl_certificate /config/keys/cert.crt;
|
|
||||||
ssl_certificate_key /config/keys/cert.key;
|
|
||||||
|
|
||||||
client_max_body_size 0;
|
|
||||||
|
|
||||||
#letsencrypt challenge response
|
|
||||||
location ~/.well-known/acme-challenge/(.*)$ {
|
|
||||||
return 200 '$1';
|
|
||||||
}
|
|
||||||
|
|
||||||
location / {
|
|
||||||
try_files $uri $uri/ /index.html /index.php?$args =404;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
HASS_DOMAIN=xxxxxxxxx
|
||||||
|
HASS_PASSWORD=xxxxxxxxx
|
||||||
|
SERVER_IP=xxxxxxxxx
|
||||||
Reference in New Issue
Block a user