Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Raspberry Homer Container not running #491

Closed
luisfco667 opened this issue Jul 26, 2022 · 28 comments
Closed

Raspberry Homer Container not running #491

luisfco667 opened this issue Jul 26, 2022 · 28 comments

Comments

@luisfco667
Copy link

sorry not sure if this is the right channel to ask a question.
But Im trying to run homer dash board on raspberry pi 4 sw buster over docker-compose and the containers showed as healthy but when I try to acces to the ip and port it not show anything .

From container logs I got only this:

Starting webserver
4147-08-20 07:32:16: (server.c.1568) server started (lighttpd/1.4.64)
4147-08-20 07:32:16: (server.c.263) warning: clock jumped -68719476736 secs

@fbartels
Copy link
Contributor

Hi @luisfco667,

this error has been reported before and is supposedly fixed in the latest container: #480 (comment)

@luisfco667
Copy link
Author

Thanks for quick replay @fbartels

I check today the #480 and follow the latest docker-compose.yml template but still the same issue.


version: "2"
services:
homer:
image: b4bz/homer:latest
#To build from source, comment previous line and uncomment below
#build: .
container_name: homer
volumes:
- /your/local/assets/:/www/assets
ports:
- 8089:8080
user: 1001:1001 # default
environment:
- INIT_ASSETS=1 # default

@fbartels
Copy link
Contributor

Did you run docker-compose pull?

@luisfco667
Copy link
Author

[+] Running 1/1
⠿ homer Pulled

then

Starting webserver
4147-08-20 07:32:16: (server.c.1568) server started (lighttpd/1.4.64)
4147-08-20 07:32:16: (server.c.263) warning: clock jumped -68719476736 secs
Starting webserver
4147-08-20 07:32:16: (server.c.1568) server started (lighttpd/1.4.64)
4147-08-20 07:32:16: (server.c.263) warning: clock jumped -68719476736 secs

@fbartels
Copy link
Contributor

Hmm.. unfortunately I am not running the container myself, so i don't have a good idea how to troubleshoot further. Maybe someone else has an idea?

@luisfco667
Copy link
Author

thanks @fbartels for the help

@bastienwirtz
Copy link
Owner

Hi there,

@luisfco667 Can you post the result of this command:

docker exec -it homer cat /lighttpd.conf

Thanks,

@luisfco667
Copy link
Author

server.port =env.PORT
server.modules = ( "mod_alias" )
serverusername = "lighttpd"
server.groupname = "lighttpd"
server.document-root = "/www"
alias.url = ( env.SUBFOLDER => '/www" )
server.indexfiles = ("index.html")
server.follow-symkink = "enable"
server.feature-flags +=( "server.clock-jump-restart" => 0 )

@bastienwirtz
Copy link
Owner

Ok so, you do have the latest patch regarding the clock-jump issue mentioned by @fbartels, and that should not be the issue (otherwise the warning would be followed be a server restart log).

Could you share your compose file and the exacte URL you try to access ? thanks.

@luisfco667
Copy link
Author

hi ,

this is the compose Im using:


version: "2"
services:
homer:
image: b4bz/homer
#To build from source, comment previous line and uncomment below
#build: .
container_name: homer
volumes:
- /mnt/nas/drive01/Docker/homer/assets/:/www/assets
ports:
- 8089:8080
user: 1001:1001 # default
environment:
- INIT_ASSETS=1 # default

this is the log file from portainer:

No configuration found, installing default config & assets
Starting webserver
4147-08-20 07:32:16: (server.c.1568) server started (lighttpd/1.4.64)
4147-08-20 07:32:16: (server.c.263) warning: clock jumped -68719476736 secs

this is the url im trying to use to access:

http://10.0.0.220:8089/

and this output from command:

admin@Server01:/mnt/nas/drive01/Docker/homer/assets $ docker exec -it homer cat /lighttpd.conf
include "/etc/lighttpd/mime-types.conf"

server.port = env.PORT
server.modules = ( "mod_alias" )
server.username = "lighttpd"
server.groupname = "lighttpd"
server.document-root = "/www"
alias.url = ( env.SUBFOLDER => "/www" )
server.indexfiles = ("index.html")
server.follow-symlink = "enable"
server.feature-flags += ( "server.clock-jump-restart" => 0 )

@bastienwirtz
Copy link
Owner

I don't see anything wrong 🤔
Could you share the result of :

curl -IX GET http://10.0.0.220:8089/
curl http://10.0.0.220:8089/

Thanks

@luisfco667
Copy link
Author

admin@Server01:~ $ curl -IX GET http://10.0.0.220:8089/
curl: (7) Failed to connect to 10.0.0.220 port 8089: Connection refused

admin@Server01:~ $ curl http://10.0.0.220:8089/
curl: (7) Failed to connect to 10.0.0.220 port 8089: Connection refused

8089/tcp ALLOW Anywhere # homerDashBoard
8089/tcp (v6) ALLOW Anywhere (v6) # homerDashBoard

@anchorcoding
Copy link

Is there any solution for this. Having the same issue :(

@luisfco667
Copy link
Author

no so far

@bastienwirtz
Copy link
Owner

bastienwirtz commented Sep 5, 2022

@luisfco667 Can you try the curl command on the docker host with 127.0.0.1 instead of 10.0.0.220?

Also you can execute this command to make sure homer is working:

docker exec -it homer curl -IX GET http://127.0.0.1:8080/

If this command is successful (returns HTTP/1.1 200 OK with some html content), your homer instance is working properly, but something else (firewall ?) is blocking the request.

@luisfco667
Copy link
Author

@bastienwirtz today before try I did one update & upgrade (I did many times in the past) now it show some data to output as bellow but still not show the dashboard ( I disabled UFW) :

admin@Server01:~ $ curl -IX GET http://10.0.0.220:8089/
HTTP/1.1 200 OK
Content-Type: text/html
ETag: "3294342249"
Last-Modified: Fri, 29 Jul 2022 17:19:33 GMT
Content-Length: 729
Accept-Ranges: bytes
Date:
Server: lighttpd/1.4.64

admin@Server01:~ $ curl -IX GET http://127.0.0.1:8089/
HTTP/1.1 200 OK
Content-Type: text/html
ETag: "3294342249"
Last-Modified: Fri, 29 Jul 2022 17:19:33 GMT
Content-Length: 729
Accept-Ranges: bytes
Date:
Server: lighttpd/1.4.64

@bastienwirtz
Copy link
Owner

Ok, 200 OK is good! Can you curl without the -I to see if homer HTML is returned ?

When you say not show the dashboard, you mean an empty white page in your browser ? In this case, try to look for errors in the browser dev tool (console & network tab) to see if anything shows up.

@tomtreffke
Copy link

tomtreffke commented Sep 20, 2022

Hi there, I would like to loop into this shortly. I can confirm most of the behavior @luisfco667 has had here, but I'll paste the outputs of various cmds anyway below. First, the error i have is:
This page doesnt work, pihole.box (the container host, a Raspi 3B+) has delivered an invalid response.
image

now to the commands/outputs, they look actually the same:

docker exec -it 61a03f5d6d63 cat /lighttpd.conf

 include "/etc/lighttpd/mime-types.conf"

server.port            = env.PORT
server.modules         = ( "mod_alias" )
server.username        = "lighttpd"
server.groupname       = "lighttpd"
server.document-root   = "/www"
alias.url              = ( env.SUBFOLDER => "/www" )
server.indexfiles      = ("index.html")
server.follow-symlink  = "enable"
server.feature-flags  += ( "server.clock-jump-restart" => 0 )

curl -IX GET http://pihole.box:8084 (i set portainer to expose 8084 (:8080))

HTTP/1.1 200 OK
Content-Type: text/html
ETag: "1285829416"
Last-Modified: Sun, 18 Sep 2022 14:40:31 GMT
Content-Length: 768
Accept-Ranges: bytes
Date: 
Server: lighttpd/1.4.64

curl http://pihole.box:8084

<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <link rel="icon" href="assets/icons/favicon.ico" />
    <link rel="apple-touch-icon" href="assets/icons/apple-touch-icon.png" sizes="180x180">
    <link rel="mask-icon" href="assets/icons/logo.svg">
    <meta name="viewport" content="width=device-width,initial-scale=1.0,viewport-fit=cover">
    <title>Homer</title>
    <script type="module" crossorigin src="./resources/index.5f7af6ed.js"></script>
    <link rel="stylesheet" href="./resources/index.93280153.css">
  <link rel="manifest" href="./assets/manifest.json" crossorigin="use-credentials"><script id="vite-plugin-pwa:register-sw" src="./registerSW.js"></script></head>
  <body>
    <div id="app-mount"></div>
    
  </body>
</html>

Both Postman and Thunderclient (an API Tester for VSCode) give an error when calling:
GET http://pihole.box:8084

Parse Error: Invalid header value char

@tomtreffke
Copy link

tomtreffke commented Sep 20, 2022

I noticed, that my container log looks like this:

Starting webserver
4147-08-20 07:32:16: (server.c.1568) server started (lighttpd/1.4.64)
4147-08-20 07:32:16: (server.c.263) warning: clock jumped -68719476736 secs
1970-01-01 00:00:00: (connections.c.717) unexpected TLS ClientHello on clear port (192.168.178.20)
1970-01-01 00:00:00: (connections.c.717) unexpected TLS ClientHello on clear port (192.168.178.20)
1970-01-01 00:00:00: (connections.c.717) unexpected TLS ClientHello on clear port (192.168.178.20)
1970-01-01 00:00:00: (connections.c.717) unexpected TLS ClientHello on clear port (192.168.178.20)
(...ongoing with the unexpected TLS ClientHello on clear port)

@tomtreffke
Copy link

last comment for today. setting following flag on lighttpd.conf
server.http-parseopt-header-strict = "disable"
-> I think it didnt work, because I couldnt update the file in place, I forced lighttpd to use it with lighttpd -f /www/assets (where i placed the update version via vscode-ssh) ... I think inplace-replacement doesnt work really and one would have to rebuild the container to test this, but I'm also not to optimistic on that one. Corresponding change on lighttpd is > 6 years old...

using older versions of the docker container also didnt work for me. I tried: latest, [v22.08.1], [v22.07.2] and the error is the same.

@bastienwirtz
Copy link
Owner

Hi @tomtreffke,

From your first comment, everything seems to work great. Your curl request ends up in 200 ok and the HTML returned is Homer's code.

I'm not sure what you trying to do with Postman and Thunderclient as Homer doesn't have an API.
Your container log shows (unexpected TLS ClientHello on clear port) that you might try to access Homer using httpS (it's not supported by Homer)?

@tomtreffke
Copy link

tomtreffke commented Sep 21, 2022

Hi @bastienwirtz, I thought I just utilize Postman/Thunderclient to issue GET requests onto the endpoint. Which in turn gives me a little more insights in what the issue is. How else do you explain the attached screenshot?

I dont try to call https. I am calling http://pihole.box:8084.

What I just noticed: I always used chromium to test. I now checked with Firefox and it just works.
Chrome on iPhone does not work as well. same issue here.
Both Firefox and Chromium (on my Laptop) have the HTTPs-Only-Mode deactivated.

update: i checked on my Samsung TV (Tizen, also uses Chromium) and its also an empty page (no HTTP error code though)

@bastienwirtz
Copy link
Owner

Hum that's weird 🤔
Does your chromium shows any errors in the web console?

@Nicooo27
Copy link

The same thing happens to me with the latest version and I can't get it to start, I already put the permissions of 1000:1000 and u+wr and it still won't start.

@mahnat
Copy link

mahnat commented Nov 1, 2022

Hello, I would like to report the same behavior here and the solution.

Container using latest homer image started via portainer.io web UI on Raspberry Pi 4 running 32bit Raspbian 10 (buster).
Curl return content/code 200 for HTTP, but Edge browser return ERR_INVALID_HTTP_RESPONSE
Curl for HTTPS return curl: (35) error:0A00010B:SSL routines::wrong version number error and container log got a new message logged: 1970-01-01 00:00:00: (connections.c.717) unexpected TLS ClientHello on clear port (192.168.0.20).
Edge browser on HTTPS return ERR_SSL_PROTOCOL_ERROR (as expected).

Log message timestamp seems suspicious so checking the date in the container confirms it is not just incorrect but also inconsistent:

root@pi:~# docker exec -it  homer date
Fri Jul 17 07:34:32 CEST 2071
root@pi:~# docker exec -it  homer date
Thu Apr 30 09:04:08 CEST 2071
root@pi:~# docker exec -it  homer date
Sat Jun 13 03:14:16 CEST 2071
root@pi:~#

Further investigation of incorrect time in containers pointed to the libsseccomp library issue. More information and solution found in different project issue comment: #nodejs/docker-node#1589 (comment)

So this is not an homer issue but issue of docker. If you are running 32bit Raspbian Linux on your Raspberry Pi, you are most probably affected by this problem and need to update libseccomp library manually or upgrade to a newer/64bit Raspbian OS.

@tomtreffke
Copy link

tomtreffke commented Nov 3, 2022

@mahnat very nice, I updated my libseccomp binary manually from raspbian and it works on most chromium based browsers now.

@bastienwirtz
Copy link
Owner

Well done @mahnat! Thanks for sharing the solution.
I'm closing this issue as it's resolved, feel free to reopen if anything.

@mkizzle2906
Copy link

in containers pointed to the libsseccomp library issue. More information and solution found in different project issue comment: #nodejs/docker-node#1589 (comment)

can you show me how to update it ? i have the same issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants