question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

HTTP(s) webserver not starting

See original GitHub issue

I’m runing hass-emulated-hue in a standalone docker (not as add-on). HUE Bridge cannot be found on the network. Also port 80 or 443 or not responding on the IP of the docker container.

Steps to Reproduce

Start the docker image:

docker run --name=hass-emulated-hue -hostname=hass-emulated-hue -e TZ=Europe/Amsterdam -e \
  HASS_URL=https://homeassistant.example.com -e HASS_TOKEN=*** -e VERBOSE=true --network lan-static --ip x.x.x.x \   -v hass-emulated-hue-config:/config/.emulated-hue ghcr.io/hass-emulated-hue/core:latest

Expected behavior

HUE Bridge is discoverable on the network. Also ports 80 and/or 443 should at least make a TCP connection. While browsing other issues, I noticed that the logs should contain lines like these:

emulated_hue.api -- Started HTTP webserver on port 80
emulated_hue.api -- Started HTTPS webserver on port 443

but those are not in my logs.

Logs

Output from docker container:

[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 00-set-vars.sh: executing...
[21:31:30] INFO: Starting Emulated Hue...
[cont-init.d] 00-set-vars.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
2022-06-08 21:31:30,501 DEBUG emulated_hue.utils -- Loading /root/.emulated_hue/emulated_hue.json failed: [Errno 2] No such file or directory: '/root/.emulated_hue/emulated_hue.json'
2022-06-08 21:31:30,507 INFO  emulated_hue.config -- Auto detected listen IP address is x.x.x.x
2022-06-08 21:31:30,519 DEBUG getmac -- Raw MAC found: None
2022-06-08 21:31:30,522 DEBUG getmac -- Raw MAC found: 00:50:56:ba:6b:8a

2022-06-08 21:31:30,525 DEBUG aiorun -- Entering run()
2022-06-08 21:31:30,537 DEBUG aiorun -- Creating default executor
2022-06-08 21:31:30,561 INFO  hass_client -- Connected to Home Assistant wss (version 2022.6.4)

Also I see a log entry in Home Assistant when the container starts:

[140174100621440] Client unable to keep up with pending messages. Stayed over 512 for 5 seconds

Hardware Info:

  • Architecture: x86
  • Addon version: ghcr.io/hass-emulated-hue/core:latest
  • OS: Docker: VMWare VCH, HASS: Supervised
  • Hardware : PC/Server

Issue Analytics

  • State:open
  • Created a year ago
  • Comments:10 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
alexyao2015commented, Sep 12, 2022

@meden The image uses host networking which allows direct access to host ports. You will therefore not see any port mappings. The ports uses can be configured in the config options.

@fjgalesloot I’m not entirely sure what could be happening here. Can you list the steps that you took to reproduce this from a clean home assistant install? I am unable to reproduce this.

0reactions
alexyao2015commented, Nov 22, 2022

This message here is key s6-overlay-suexec: fatal: can only run as pid 1.. This occurs because something is overriding the default entrypoint. Oftentimes there is some setting to disable this behavior termed init which you’ll need to find.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why is SSL/HTTPS not working on my site? - Support | one.com
There can be several reasons why SSL/HTTPS is not working on your site. Please see if one of the causes listed below helps...
Read more >
Troubleshooting HTTP Server - IBM
Symptom: HTTP Server on port 80 does not start · Click the Manage tab. · Click the HTTP Servers subtab. · Select APACHEDFT...
Read more >
Troubleshooting: Apache Webserver Will Not Restart / Start
My CentOS Apache 2 (httpd) webserver will not start. It was working fine but I made few changes to httpd.conf and it is...
Read more >
Solved: httpd WebServer not starting - SAS Communities
Re: httpd WebServer not starting​​ It looks like that other process is running on the same port, thats why Web server can not...
Read more >
How to Fix the Apache Server Not Starting in MAMP Error (In 4 ...
Summary · Ensure that Skype isn't running, as it can interfere with the Apache server. · Verify that no other instances of Apache...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found