Announcement

Collapse
No announcement yet.

HS4 Homeseer Linux - Docker Image & Repository

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #16
    Originally posted by savageautomate View Post
    Updated repository to include support for:Additional Resources:
    Ok... I installed in via the YML file from the Github page. Not sure what version that makes it?

    Anyways, I changed the port from 80:80 to 82:80 (Have Apache running).... ran docker compose...

    Went to the web page and port... It asked for my username-- great!

    default/default

    Log shows:

    homeseer | 07:48:10:9163:[Web Server]->Web Server authorized login successful from: 192.168.0.6 User: default

    But I don't see any pages returned! I tried /homeseer/html/index.html and all sorts of permutations.

    All the files look readable through the heirarchy?

    -rwxr-xr-x 1 root root 6902 Mar 10 2020 index.html
    ​-------------------
    Shut of Apache and web to port 80... working now... Changing settings.ini
    Changed the settings to port 82 in Homeseer-- same issue.

    Something is causing this to only work on port 80.
    HS3 Pro Edition 3.0.0.435 (Windows Server 8.1 on ESXi box)

    Plug-Ins Enabled:
    Z-Wave:,RaspberryIO:,AirplaySpeak:,Ecobee:,
    weatherXML:,JowiHue:,APCUPSD:,PHLocation:,Chromecast:,EasyTr igger:

    Comment


      #17
      Ok, so I did a system restore within the container. I had to work through a few issues to get it to boot. I am sure the first couple are mostly Linux HS things.

      The settings.ini file had some script path stuff at the top. Linux didn't find those and caused a reboot. I just comment out that line. I don't even think I was using half that stuff anymore anyways.


      In the settings file, I also shut off the binding to an IP address. This is a configuration in the lab settings. After that, the web browser came up.


      Once that happened, I was able to see all the devices. I had to manually readd the plug ins, and most of them seemed to bring over the settings just fine. I had a one of two that didn't work- but I think that was because I might have had the HS3 legacy version of the plugin and didn't upgrade.

      Where things went downhill was on the plugins that use the subnet. For example, the Chromecast plugin checks the subnet (I think via mDNS) to see what Google devices are present. I think Airplay is similar. The AK Google plugin also seemed to require me to use a local web browse on the machine to get a Google Token. That I could work around

      I tried forwarding the mDNS port. (5353) No luck. I've kicked back on the Windows instance-- but maybe I will try another port tomorrow. (5009). I think the AK Googlecast has more options for discovery so maybe that would work.

      https://blog.oakbits.com/google-cast...onnection.html

      The other option is to run in host mode-- but I think you can only have one container in that case...
      HS3 Pro Edition 3.0.0.435 (Windows Server 8.1 on ESXi box)

      Plug-Ins Enabled:
      Z-Wave:,RaspberryIO:,AirplaySpeak:,Ecobee:,
      weatherXML:,JowiHue:,APCUPSD:,PHLocation:,Chromecast:,EasyTr igger:

      Comment


        #18
        Originally posted by savageautomate View Post
        Updated repository to include support for:Additional Resources:
        savageautomate Many thanks for the work on this update. I have been running in Docker on Synology for a number of years, first on HS3 then on HS4. I am moving into Proxmox with LXC. No issues with config, but have one issue I have posted on your github page. Seems I am unable to install plugins. It's really strange. I have tried all sorts of different configurations to isolate, but so far no luck. Any thoughts?

        https://github.com/HomeSeerLinux/hom...ocker/issues/2

        Comment


          #19
          Just want to report in. I have been using this now for a few months and it works fantastic.

          I had to create a macvlan so that Homeseer could see the other services running on the same machine in docker (Homebridge, MQTT, NodeRed).

          My HS instance is 192.168.0.5 (its own IP) but it runs on host 192.168.0.8. Docker protects instances from seeing the host instances- so I had to create a LAN and I have a virtual IP address 192.168.0.7.

          I run the following linux commands... so they can talk over the vlan.

          sudo ip link add mynet-shim link ens160 type macvlan mode bridge
          sudo ip addr add 192.168.0.7/32 dev mynet-shim

          sudo ip link set mynet-shim up
          sudo ip route add 192.168.0.5/32 dev mynet-shim


          In my "sudo crontab -e" editor I call the above script.

          ReBoot /home/wpiman/Docker/homeseer-docker/networkLink.sh

          Here is my docker-compose.yml file..... It has been running a long time now so it is very stable.

          [CODE]

          version: '3.8'

          volumes:
          homeseer-data:
          name: homeseer-data

          networks:
          lan:
          driver: macvlan
          driver_opts:
          parent: ens160
          ipam:
          config:
          - subnet: 192.168.0.0/24
          gateway: 192.168.0.1
          ip_range: 192.168.0.5/32
          aux_addresses:
          host: 192.168.0.7

          services:
          homeseer:
          container_name: homeseer
          build: .
          hostname: homeseer
          image: homeseer/homeseer:latest
          hostname: homeseer
          restart: unless-stopped
          networks:
          lan:
          ipv4_address: 192.168.0.5
          environment:
          TZ: America/New_York
          LANG: en_US.UTF-8
          DISPLAY: ${DISPLAY}
          volumes:
          - homeseer-data:/homeseer
          - $HOME/.Xauthority:/root/.Xauthority:rw
          command: sh -c "apt-get update && apt-get install -y vim && apt-get install -y ffmpeg && /usr/local/sbin/homeseer"
          HS3 Pro Edition 3.0.0.435 (Windows Server 8.1 on ESXi box)

          Plug-Ins Enabled:
          Z-Wave:,RaspberryIO:,AirplaySpeak:,Ecobee:,
          weatherXML:,JowiHue:,APCUPSD:,PHLocation:,Chromecast:,EasyTr igger:

          Comment


            #20
            Updated repository to include support for:
            Additional Resources:

            Comment


              #21
              Originally posted by jjwatmyself View Post

              savageautomate Many thanks for the work on this update. I have been running in Docker on Synology for a number of years, first on HS3 then on HS4. I am moving into Proxmox with LXC. No issues with config, but have one issue I have posted on your github page. Seems I am unable to install plugins. It's really strange. I have tried all sorts of different configurations to isolate, but so far no luck. Any thoughts?

              https://github.com/HomeSeerLinux/hom...ocker/issues/2
              Thanks for posting a resolution to the plugin download issue ... sorry, I did not see and respond to it until today. Glad to hear this HomeSeer container project is working for you!

              Comment


                #22
                Originally posted by wpiman View Post
                Just want to report in. I have been using this now for a few months and it works fantastic.
                ...
                Happy to hear you have found success with this project and its working stable for you!

                Comment


                  #23
                  So I have a question for the fellow docker users. How do you guys stop Homeseer, or reboot it?

                  I have noticed that any of the 3 options Shutdown Homeseer, shutdown system, and restart system do the same thing....

                  The last two, stop the container-- and since i have the container set to automatically restart-- I am not surprised. I thought the first one would stop the homeseer program on the container.

                  Or you could use "docker-compose down"...

                  When my instance boots up, the log always seems to say Homeseer didn't close down properly last time. I am dealing with the dreaded "loss of event actions" where I have to restore. I am wondering if this is the culprit.

                  HS3 Pro Edition 3.0.0.435 (Windows Server 8.1 on ESXi box)

                  Plug-Ins Enabled:
                  Z-Wave:,RaspberryIO:,AirplaySpeak:,Ecobee:,
                  weatherXML:,JowiHue:,APCUPSD:,PHLocation:,Chromecast:,EasyTr igger:

                  Comment


                    #24
                    Question: how are you guys backing and restoring the container and volume?

                    Occasionally, I get a non-clean homeseer shutdown and I loose events. I am doing a restore from the GUI. It seems to be there should be a way to store the container AND volume exactly as they are and do backups that way.
                    HS3 Pro Edition 3.0.0.435 (Windows Server 8.1 on ESXi box)

                    Plug-Ins Enabled:
                    Z-Wave:,RaspberryIO:,AirplaySpeak:,Ecobee:,
                    weatherXML:,JowiHue:,APCUPSD:,PHLocation:,Chromecast:,EasyTr igger:

                    Comment


                      #25
                      I am not much of a docker guy but I thought you can take snapshots of containers. Then you can just revert back to that snapshot.

                      Btw, why run HS in docker? I believe docker deployments are not officially supported and it adds more complexity. HS is already self-contained so simple folder copies should work fine. There must be a reason as others are doing it as well.

                      Comment


                        #26
                        Updated repository to include support for:
                        Additional Resources:

                        Comment


                          #27
                          Originally posted by wpiman View Post
                          Question: how are you guys backing and restoring the container and volume?

                          Occasionally, I get a non-clean homeseer shutdown and I loose events. I am doing a restore from the GUI. It seems to be there should be a way to store the container AND volume exactly as they are and do backups that way.
                          I ran my HomeSeer in a Docker container for a couple of years without issue, but I recently moved back to a VM to deal with some additional hardware interfaces/integration. So basically just an Ubuntu VM then running this installation https://github.com/HomeSeerLinux/hom...inux.github.io
                          I hope to move back to Docker at some point.

                          As far as storing the container image, if following the suggested install examples (https://github.com/HomeSeerLinux/homeseer-docker) where the HomeSeer directory is mapped as a volume into the container, then there really is not much of a reason to store the container itself as it never changes. The Docker images are public hosted and archived at https://hub.docker.com/repository/do...meseer/general.

                          As far as backing up the HomeSeer mapped volume (directory), I did and would highly suggest backing this up on a daily basis. I used a schedule backup software that basically just takes RSYNC copies of the entire homeseer directory/volume and copied them over to my NAS. To restore, I could restore HomeSeer either by using the automated HomeSeer backup files copied over to the NAS via the HomeSeer web UI --- or if something more serious was corrupt I could restore the entire contents of the mapped homeseer directory/volume. So that was my approach and I'm sure I had to use it once or twice to recover a non-working HomeSeer installation. But I have never completely lost my HomeSeer data where it was unrecoverable.

                          Comment


                            #28
                            Originally posted by mulu View Post
                            I am not much of a docker guy but I thought you can take snapshots of containers. Then you can just revert back to that snapshot.

                            Btw, why run HS in docker? I believe docker deployments are not officially supported and it adds more complexity. HS is already self-contained so simple folder copies should work fine. There must be a reason as others are doing it as well.
                            No running HomeSeer in Docker is not officially supported.

                            In my case, I created the Docker image because I wanted to run HomeSeer on my dedicated NAS hardware appliance (Synology) which did support containers but did not support VMs. Running HomeSeer in a container is far more lightweight (resource-wise) than running an entire VM or dedicated hardware. It's far easier and faster to redeploy, recreate or move a Homeseer container rather than a VM or physical hardware.

                            Is running HomeSeer in a Docker container the right choice for someone unfamiliar with Docker or containerization ... probably not. Surely there are complexities involved and a learning curve to overcome.

                            Comment


                              #29
                              Originally posted by wpiman View Post
                              So I have a question for the fellow docker users. How do you guys stop Homeseer, or reboot it?

                              I have noticed that any of the 3 options Shutdown Homeseer, shutdown system, and restart system do the same thing....

                              The last two, stop the container-- and since i have the container set to automatically restart-- I am not surprised. I thought the first one would stop the homeseer program on the container.

                              Or you could use "docker-compose down"...

                              When my instance boots up, the log always seems to say Homeseer didn't close down properly last time. I am dealing with the dreaded "loss of event actions" where I have to restore. I am wondering if this is the culprit.
                              You might need to review the container log as its attempting to shutdown to see if things are working properly. Take a look at this script file (https://github.com/HomeSeerLinux/hom.../sbin/homeseer) as it is supposed to handle the cases of shutdown and restart requests and perform a clean shutdown of HomeSeer including when use the shutdown and restart options from within the web app. It's entirely possible something has changed in HomeSeer and maybe the script is not properly accounting for it. In theory stopping or restarting the container using Docker commands or using the HomeSeer web UI options under "Tools/System" menu should work.

                              Comment


                                #30
                                Originally posted by wpiman View Post
                                So I have a question for the fellow docker users. How do you guys stop Homeseer, or reboot it?

                                ... The last two, stop the container-- and since i have the container set to automatically restart-- I am not surprised. I thought the first one would stop the homeseer program on the container.
                                The HomeSeer process is the main runtime process for the container so if it gets stopped, exits or crashes, then the entire container will exit/stop. I think this is common behavior for most containerized apps.

                                Comment

                                Working...
                                X