Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Bookmarks
  • Search
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

Cloudron Forum

Apps - Status | Demo | Docs | Install
  1. Cloudron Forum
  2. Home Assistant
  3. external devices - zigbee

external devices - zigbee

Scheduled Pinned Locked Moved Solved Home Assistant
29 Posts 5 Posters 8.1k Views 6 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    rjousse18
    wrote on last edited by
    #5

    How could it be implemented ? Via the app settings in cloudron with a section where we could choose what usb device(s) the app can access ?

    1 Reply Last reply
    1
    • nebulonN Offline
      nebulonN Offline
      nebulon
      Staff
      wrote on last edited by
      #6

      Yes I think that would be the idea, maybe a free flow text input which binds the mentioned device(s) into the container. Similar to what we do for vaapi device access https://git.cloudron.io/platform/box/-/blob/master/src/docker.js?ref_type=heads#L409

      1 Reply Last reply
      1
      • R Offline
        R Offline
        rjousse18
        wrote on last edited by rjousse18
        #7

        If it's, for now, specific to Home Assistant app, why not just use workarounds like https://community.home-assistant.io/t/home-assistant-in-docker-pass-usb-device-from-host/184674/2 or https://community.home-assistant.io/t/home-assistant-in-docker-pass-usb-device-from-host/184674/6 ?

        1 Reply Last reply
        1
        • nebulonN Offline
          nebulonN Offline
          nebulon
          Staff
          wrote on last edited by
          #8

          Alright, we have added initial basic support for attaching devices from the host to the container. For the moment this will just be a list of devices with a 1to1 mapping. So for example /dev/ttyUSB0 from the host can then be mapped to /dev/ttyUSB0 within the container.

          1 Reply Last reply
          3
          • R Offline
            R Offline
            rjousse18
            wrote on last edited by
            #9

            nice ! when will we be able to test this feature on home assistant ?

            1 Reply Last reply
            0
            • J Online
              J Online
              joseph
              Staff
              wrote on last edited by
              #10

              @rjousse18 8.2 is in unstable. if you update to the unstable, you can test it out - https://docs.cloudron.io/apps/#devices

              1 Reply Last reply
              0
              • R Offline
                R Offline
                rjousse18
                wrote on last edited by
                #11

                Hi ! Zigbee not working even after usb device added in "device" section.

                1 Reply Last reply
                0
                • nebulonN Offline
                  nebulonN Offline
                  nebulon
                  Staff
                  wrote on last edited by
                  #12

                  Most likely it is a permissions issue, can you open a webterminal into the app and check the group ownership of the node?

                  ls -l /dev/<yourdevice>
                  
                  1 Reply Last reply
                  0
                  • R Offline
                    R Offline
                    rjousse18
                    wrote on last edited by
                    #13

                    image.png

                    1 Reply Last reply
                    0
                    • R Offline
                      R Offline
                      rjousse18
                      wrote on last edited by
                      #14

                      chmod 777 resolved the problem but not sure it's a good idea lol

                      1 Reply Last reply
                      0
                      • J Online
                        J Online
                        joseph
                        Staff
                        wrote on last edited by
                        #15

                        Probably don't need the 'x' bit on devices. So 666 maybe.

                        1 Reply Last reply
                        0
                        • nebulonN Offline
                          nebulonN Offline
                          nebulon
                          Staff
                          wrote on last edited by
                          #16

                          ah good next package release will add the cloudron user to the dialout group, that should fix it also in the long run then.

                          1 Reply Last reply
                          3
                          • R Offline
                            R Offline
                            rjousse18
                            wrote on last edited by
                            #17

                            not fixed with the latest stable release, juste to mention

                            1 Reply Last reply
                            0
                            • nebulonN Offline
                              nebulonN Offline
                              nebulon
                              Staff
                              wrote on last edited by
                              #18

                              oh indeed, the change didn't make it. Will include it with next release then

                              1 Reply Last reply
                              0
                              • R Offline
                                R Offline
                                rjousse18
                                wrote on last edited by
                                #19

                                Just updated to 1.1.0. Still not working, had to chmod

                                1 Reply Last reply
                                0
                                • nebulonN Offline
                                  nebulonN Offline
                                  nebulon
                                  Staff
                                  wrote on last edited by
                                  #20

                                  Just did another test install and at least my ttyUSB0 device would show up correctly with:

                                  > ls -l /dev/tty*
                                  crw-rw-rw- 1 root root      5, 0 Feb 16 12:18 /dev/tty
                                  crw-rw-rw- 1 root dialout 188, 0 Feb 16 12:18 /dev/ttyUSB0
                                  

                                  So in your case you still had to add read-write access to the group for your device?

                                  1 Reply Last reply
                                  0
                                  • R Offline
                                    R Offline
                                    rjousse18
                                    wrote on last edited by
                                    #21

                                    Yep, as you can see, /dev/ttyACM0 has no right for group :

                                    image.png

                                    1 Reply Last reply
                                    0
                                    • nebulonN Offline
                                      nebulonN Offline
                                      nebulon
                                      Staff
                                      wrote on last edited by
                                      #22

                                      actually the group permissions are rw only others have no access. So this looks correct to me.

                                      1 Reply Last reply
                                      0
                                      • R Offline
                                        R Offline
                                        rjousse18
                                        wrote on last edited by
                                        #23

                                        but it didn't works 😕 I had to chmod again, is there any solution to launch a script at startup ? I don't want to chmod every time the app is updated

                                        1 Reply Last reply
                                        0
                                        • nebulonN Offline
                                          nebulonN Offline
                                          nebulon
                                          Staff
                                          wrote on last edited by
                                          #24

                                          So to be on the same page, if you give read/write permissions to all users HomeAssistant can use the device fine, but not if only root and dialout group have it? Reason I ask is, since HomeAssistant as such runs with the dialout group. Which kind of integration is this? Maybe it spawns other processes which run as different user?

                                          Since I can't reproduce this locally, maybe you can send a mail to support@cloudron.io if you want us to take a direct look at your case to get this fixed.

                                          1 Reply Last reply
                                          0

                                          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                                          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                                          With your input, this post could be even better 💗

                                          Register Login
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • Bookmarks
                                          • Search