chore: log reason reverse proxy can't be started (#1089)

Following on to #1065, the reason that the reverse proxy cannot be started (such as an invalid cache server URL) wasn't being logged.

<!--start release-notes-assistant-->
<!--URL:https://code.forgejo.org/forgejo/runner-->
- other
  - [PR](https://code.forgejo.org/forgejo/runner/pulls/1089): <!--number 1089 --><!--line 0 --><!--description Y2hvcmU6IGxvZyByZWFzb24gcmV2ZXJzZSBwcm94eSBjYW4ndCBiZSBzdGFydGVk-->chore: log reason reverse proxy can't be started<!--description-->
<!--end release-notes-assistant-->

Reviewed-on: https://code.forgejo.org/forgejo/runner/pulls/1089
Reviewed-by: Mathieu Fenniak <mfenniak@noreply.code.forgejo.org>
Reviewed-by: earl-warren <earl-warren@noreply.code.forgejo.org>
Co-authored-by: Andrew Cassidy <drewcassidy@me.com>
Co-committed-by: Andrew Cassidy <drewcassidy@me.com>
This commit is contained in:
Andrew Cassidy 2025-10-14 08:08:03 +00:00 committed by earl-warren
parent 05795ee286
commit 2de7e57e08
No known key found for this signature in database
GPG key ID: F128CBE6AB3A7201

View file

@ -82,7 +82,7 @@ func StartHandler(targetHost, outboundIP string, port uint16, cacheProxyHostOver
proxy, err := h.newReverseProxy(targetHost)
if err != nil {
return nil, fmt.Errorf("unable to set up proxy to target host")
return nil, fmt.Errorf("unable to set up proxy to target host: %v", err)
}
router := httprouter.New()