1
0
Fork 0
mirror of https://code.forgejo.org/forgejo/runner.git synced 2025-10-20 19:52:06 +00:00

fix: log error for why cache couldn't be started (#1057)

Example, `cache.port` set to `22`:
```
time="2025-10-04T09:27:42-06:00" level=error msg="Could not start the cache server, cache will be disabled: listen tcp :22: bind: permission denied" func="[setupCache]" file="[runner.go:126]"
```

<!--start release-notes-assistant-->
<!--URL:https://code.forgejo.org/forgejo/runner-->
- bug fixes
  - [PR](https://code.forgejo.org/forgejo/runner/pulls/1057): <!--number 1057 --><!--line 0 --><!--description Zml4OiBsb2cgZXJyb3IgZm9yIHdoeSBjYWNoZSBjb3VsZG4ndCBiZSBzdGFydGVk-->fix: log error for why cache couldn't be started<!--description-->
<!--end release-notes-assistant-->

Reviewed-on: https://code.forgejo.org/forgejo/runner/pulls/1057
Reviewed-by: limiting-factor <limiting-factor@noreply.code.forgejo.org>
Co-authored-by: Mathieu Fenniak <mathieu@fenniak.net>
Co-committed-by: Mathieu Fenniak <mathieu@fenniak.net>
This commit is contained in:
Mathieu Fenniak 2025-10-05 07:40:06 +00:00 committed by earl-warren
parent 4010e61165
commit ba1beb08f4
No known key found for this signature in database
GPG key ID: F128CBE6AB3A7201

View file

@ -123,7 +123,7 @@ func setupCache(cfg *config.Config, envs map[string]string) *cacheproxy.Handler
log.StandardLogger().WithField("module", "cache_request"),
)
if err != nil {
log.Error("Could not start the cache server, cache will be disabled")
log.Errorf("Could not start the cache server, cache will be disabled: %v", err)
return nil
}