Closed foxt closed 9 months ago
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
If you stopped Homebridge first with hb-service stop
the upgrade should work.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
god i wish my software bugs were fixed by having people not talk about them for a month
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
god i wish my software bugs were fixed by having people not talk about them for a month
@foxt you can submit a PR. Currently have no plans to implement.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
This issue has been closed as no further activity has occurred.
Analysis
Attempting to upgrade Homebridge inside a LXC container results in
Expected Behavior
The upgrade succeeds
Steps To Reproduce
Logs
Configuration
Environment
Process Supervisor
hb-service
Additional Context
It seems like Homebridge is trying to see if the process indicated by
$$
has 'hb-service' anywhere in its process tree (usingpstree
), however, in LXC it is common for administrators to create a shell that is detached from the main process tree (and thus, doesn't have the init process in it's process tree), this confuses pstree and shows the tree for the init process, which will havehb-service
as a child.For example, in this case, the shell has PID 371043, which has the PPid 370985, which has the PPid 0, without the init process (1) in this chain.
Calling pstree on pid 0 without
-s
reveals this.It might be possible to check if the pstree output doesn't contain
┬
or common processes that will never own Homebridge such assystemd-resolve
?Or, you could check that an EnvVar such as
HOMEBRIDGE_APT_PACKAGE
is not set?