Skip to content
This repository was archived by the owner on Mar 5, 2022. It is now read-only.
This repository was archived by the owner on Mar 5, 2022. It is now read-only.

can't run off command within service #64

@mreassassin

Description

@mreassassin

I have a switch setup with this as the off command:

"off_cmd": "/home/pi/venv/bin/xbox-poweroff --address 192.168.1.35 --liveid FXXXXXXXXXXXXXXX"

this works fine if I run it from a terminal in PuTTy. if I put it in the off_cmd line on cmdswitch2 it fails. do I need to put it in a virtual environment (source venv/bin/activate) first? how do I make this work?

I used to run Homebridge straight from PuTTy, but i got tired of manually having to launch it if it crashed. now I set hb-service up and i'm running into all kinds of problems. this is the only one I can't seem to figure out.

i figured out how to make the 'on' command work by giving the full path. that didn't work with the off command.

any help appreciated!

` ``
{
"name": "TEST",
"on_cmd": "python /home/pi/xbox-remote-power/xbox-remote-power.py -a 192.168.1.35 -i FXXXXXXXXXXXXXXX",
"off_cmd": "/home/pi/venv/bin/xbox-poweroff --address 192.168.1.35 --liveid FXXXXXXXXXXXXXXX8",
"state_cmd": "ping -c 2 -W 1 192.168.1.35 | grep -i '2 received'",
"timeout": 200,
"manufacturer": "Microsoft",
"model": "XBOX ONE",
"serial": "XXXXXXXXXXX"
}


Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions