Closed jryom closed 2 months ago
In the meantime, this is my way of running it within a container. I do all of this with the portainer web app on my NAS.
Dockerfile (Create the image):
FROM openjdk:latest
WORKDIR /app
ADD https://github.com/stefanvictora/hue-scheduler/releases/download/v0.9.0/hue-scheduler.jar /app
Docker Compose yaml:
version: '3'
services:
my-hue-scheduler:
image: hue-scheduler:0.9.0
container_name: "hue-scheduler"
environment:
- TZ=Europe/Berlin
dns:
- <router IP>
network_mode: "bridge"
volumes:
- <host_path>:/etc/opt/hue-scheduler/
command: java -jar hue-scheduler.jar <hue bridge IP> <api-token> --lat=<lat> --long=<long> --elevation=<elevation> /etc/opt/hue-scheduler/schedules.txt
deploy:
restart_policy:
condition: on-failure
Hi @jryom, thank you for the kind words! Glad to hear that you find it useful as well. And good idea of publishing an official docker image. I'm actually currently looking into adding support for the Home Assistant API and addon system (see #8), which will also require some form of dockerization in the end. I will keep you both updated once I manage to publish an image.
Feel free to reach out if you encounter any issues or you have some further ideas for improvement! I appreciate any input :)
I have now managed to publish v0.10.0, which is fully available as a Docker image. Check it out here: https://hub.docker.com/r/stefanvictora/hue-scheduler.
Please review the updated documentation on how to provide the required arguments to the container. To summarize, the recommended way is now to provide them as environment variables, as shown in the examples. The old method of using the command
property is still supported.
If you have any questions or suggestions for improving the Docker image, feel free to reach out.
Great project, thanks a lot for making and maintaining it 🙏🏻
I'd just suggest that you make it available as a docker image. I run all my home automation/media server stuff as docker containers via docker-compose, which makes it super easy to handle updates and related files for each running container. I think publishing this as a docker image would make it easier for new users to jump in and get started :)
Thanks again 💡