this post was submitted on 31 Oct 2023
9 points (100.0% liked)
homeassistant
11884 readers
45 users here now
Home Assistant is open source home automation that puts local control and privacy first. Powered by a worldwide community of tinkerers and DIY enthusiasts. Perfect to run on a Raspberry Pi or a local server. Available for free at home-assistant.io
founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
I'd guess that it's running under a different user. You can find the user executing it and provide the key to that user via copying it to their ssh directory, or by using an identity file option for your command.
Although now that I think of it, I'd create a separate key and provide that public key to keep it separate from your user account.
I agree this is a better method.
I'm having trouble figuring out which user or container HA is using to execute the shell command. I
docker exec -it homeassistant /bin/bash
, ranssh-keygen
, and copied the pubkey into gitea, but it had no effect. I tried to run ssh-keygen in thehassio-cli
container butssh-keygen
isn't installed (so my assumption is that this isn't a container that would do something that might need a key, because HA didn't pre-load ssh-keygen - maybe I'm wrong). When Idocker inspect
the HA containers and grep for "User" or "UID", there is no result.