diff --git a/epaper-station/config.yaml b/epaper-station/config.yaml index 6fadd9a..1f9c24e 100644 --- a/epaper-station/config.yaml +++ b/epaper-station/config.yaml @@ -1,6 +1,6 @@ --- name: EPaper Station -version: 1.0.0.31 +version: 1.0.0.32 #image: ghcr.io/maxwinterstein/homeassistant-addon-toogoodtogo-ha-mqtt-bridge-{arch} slug: epaper-station description: Publish Pictures to EPaper pricetags diff --git a/epaper-station/rootfs/etc/nginx/nginx.conf b/epaper-station/rootfs/etc/nginx/nginx.conf index b0bcc69..7ca5064 100644 --- a/epaper-station/rootfs/etc/nginx/nginx.conf +++ b/epaper-station/rootfs/etc/nginx/nginx.conf @@ -1,6 +1,6 @@ daemon off; error_log /dev/stdout info; -user www-data; + events { } @@ -19,7 +19,7 @@ http { } location /input_img { - root IMG_DIR; + proxy_pass http://localhost:8080; } location /ws { diff --git a/epaper-station/rootfs/etc/services.d/image-server/run b/epaper-station/rootfs/etc/services.d/image-server/run new file mode 100644 index 0000000..177ac51 --- /dev/null +++ b/epaper-station/rootfs/etc/services.d/image-server/run @@ -0,0 +1,5 @@ +#!/usr/bin/with-contenv bashio +IMG_DIR="$(bashio::config 'image_path')" +bashio::log.info "Starting image server..." +cd $IMG_DIR +python -m SimpleHTTPServer 8080 diff --git a/epaper-station/rootfs/etc/services.d/nginx/run b/epaper-station/rootfs/etc/services.d/nginx/run index 29b9e28..0bdbf1a 100644 --- a/epaper-station/rootfs/etc/services.d/nginx/run +++ b/epaper-station/rootfs/etc/services.d/nginx/run @@ -1,6 +1,4 @@ #!/usr/bin/with-contenv bashio -IMG_DIR="$(bashio::config 'image_path')" bashio::log.info "Starting nginx..." -sed -i "s~IMG_DIR~$IMG_DIR~g" /etc/nginx/nginx.conf nginx -c /etc/nginx/nginx.conf bashio::log.info "nginx running."