[bugfix] warn on maxprocs error instead of failing (#1678)

* [bugfix] warn on maxprocs error instead of failing

* info instead of warn
This commit is contained in:
tobi 2023-04-08 11:51:24 +02:00 committed by GitHub
parent e46323c207
commit fb41d2d48f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -59,9 +59,8 @@
// Start creates and starts a gotosocial server
var Start action.GTSAction = func(ctx context.Context) error {
_, err := maxprocs.Set(maxprocs.Logger(nil))
if err != nil {
return fmt.Errorf("failed to set CPU limits from cgroup: %s", err)
if _, err := maxprocs.Set(maxprocs.Logger(nil)); err != nil {
log.Infof(ctx, "could not set CPU limits from cgroup: %s", err)
}
var state state.State