banner: build timestamp: read port from http-port.txt
This fixes the banner on devices that use a non-standard HTTP port
This commit is contained in:
parent
3d820b07fa
commit
2c1eed342d
@ -123,7 +123,11 @@ func buildTimestamp() (string, error) {
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
req, err := http.NewRequest("GET", "http://gokrazy:"+strings.TrimSpace(string(pw))+"@localhost/", nil)
|
||||
port, err := os.ReadFile("/etc/http-port.txt")
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
req, err := http.NewRequest("GET", "http://gokrazy:"+strings.TrimSpace(string(pw))+"@localhost:"+strings.TrimSpace(string(port))+"/", nil)
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user