Renew let's encrypt cert failing

While trying to renew certificates using this command:

tutor local https renew

we are getting this error:

Challenge failed for domain preview.courses.site.com

it seems that this request:

http://preview.courses.site.com/.well-known/acme-challenge/KMeTgvMqZpDRGI

is failing with 400.

Anyone with this error?

Thanks!

I see now, its related with ALLOWED_HOSTS configuration, @regis any idea on how to configure ALLOWED_HOSTS to support this case?

:thinking:I don’t think that modifying ALLOWED_HOSTS is going to solve the problem. You need to stop the nginx server in order to update the https certificates:

tutor local stop nginx
tutor local https renew
tutor local start -d
1 Like

Oh my, is working by doing that… i didn’t do the stop before the renew.

Do you want me to update https://docs.tutor.overhang.io/configuration.html#ssl-tls-certificates-for-https-access in the docs and send a PR?

Yes, that would be great, thanks. I’ll also open a new issue to improve that behaviour.

EDIT: here is the corresponding issue https://github.com/overhangio/tutor/issues/282

Done. Let me know if that is ok.

1 Like