Hi. I’m running tutor 16.1.7 (palm 4). Today I tried adding cairn to my installation, first on local. After everything was fine on local, I tried adding this plugin to the production environment. While the launch seemed successful and without errors, I’m getting 502 when visiting https://data.lms.mydomain.com
. Where should I check for error logs?
Run tutor local logs --tail=100 -f
and trigger the 502 error. What’s in the logs?
tutor_local-caddy-1 | {"level":"info","ts":1702905981.096735,"logger":"tls.obtain","msg":"obtaining certificate","identifier":"data.lms.sharifstar.com"}
tutor_local-caddy-1 | {"level":"info","ts":1702905982.7306824,"logger":"http.acme_client","msg":"trying to solve challenge","identifier":"data.lms.sharifstar.com","challenge_type":"tls-alpn-01","ca":"https://acme-staging-v02.api.letsencrypt.org/directory"}
tutor_local-caddy-1 | {"level":"error","ts":1702905984.091098,"logger":"http.acme_client","msg":"challenge failed","identifier":"data.lms.sharifstar.com","challenge_type":"tls-alpn-01","problem":{"type":"urn:ietf:params:acme:error:tls","title":"","detail":"185.143.233.82: remote error: tls: no application protocol","instance":"","subproblems":[]}}
tutor_local-caddy-1 | {"level":"error","ts":1702905984.0912304,"logger":"http.acme_client","msg":"validating authorization","identifier":"data.lms.sharifstar.com","problem":{"type":"urn:ietf:params:acme:error:tls","title":"","detail":"185.143.233.82: remote error: tls: no application protocol","instance":"","subproblems":[]},"order":"https://acme-staging-v02.api.letsencrypt.org/acme/order/129391284/13058452714","attempt":1,"max_attempts":3}
tutor_local-caddy-1 | {"level":"info","ts":1702905985.6814542,"logger":"http.acme_client","msg":"trying to solve challenge","identifier":"data.lms.sharifstar.com","challenge_type":"http-01","ca":"https://acme-staging-v02.api.letsencrypt.org/directory"}
tutor_local-caddy-1 | {"level":"error","ts":1702905989.1543777,"logger":"http.acme_client","msg":"challenge failed","identifier":"data.lms.sharifstar.com","challenge_type":"http-01","problem":{"type":"urn:ietf:params:acme:error:unauthorized","title":"","detail":"185.143.233.82: Invalid response from https://data.lms.sharifstar.com/.well-known/acme-challenge/ddzeehzEi8w__xDI8YMEiDp2ShTU5JFoGUADe-vDppk: 502","instance":"","subproblems":[]}}
tutor_local-caddy-1 | {"level":"error","ts":1702905989.1545577,"logger":"http.acme_client","msg":"validating authorization","identifier":"data.lms.sharifstar.com","problem":{"type":"urn:ietf:params:acme:error:unauthorized","title":"","detail":"185.143.233.82: Invalid response from https://data.lms.sharifstar.com/.well-known/acme-challenge/ddzeehzEi8w__xDI8YMEiDp2ShTU5JFoGUADe-vDppk: 502","instance":"","subproblems":[]},"order":"https://acme-staging-v02.api.letsencrypt.org/acme/order/129391284/13058453224","attempt":2,"max_attempts":3}
tutor_local-caddy-1 | {"level":"error","ts":1702905989.1546211,"logger":"tls.obtain","msg":"could not get certificate from issuer","identifier":"data.lms.sharifstar.com","issuer":"acme-v02.api.letsencrypt.org-directory","error":"HTTP 403 urn:ietf:params:acme:error:unauthorized - 185.143.233.82: Invalid response from https://data.lms.sharifstar.com/.well-known/acme-challenge/ddzeehzEi8w__xDI8YMEiDp2ShTU5JFoGUADe-vDppk: 502"}
tutor_local-caddy-1 | {"level":"info","ts":1702905991.880371,"logger":"http.acme_client","msg":"trying to solve challenge","identifier":"data.lms.sharifstar.com","challenge_type":"http-01","ca":"https://acme.zerossl.com/v2/DV90"}
tutor_local-caddy-1 | {"level":"error","ts":1702905999.2186599,"logger":"http.acme_client","msg":"challenge failed","identifier":"data.lms.sharifstar.com","challenge_type":"http-01","problem":{"type":"","title":"","detail":"","instance":"","subproblems":[]}}
tutor_local-caddy-1 | {"level":"error","ts":1702905999.2189317,"logger":"http.acme_client","msg":"validating authorization","identifier":"data.lms.sharifstar.com","problem":{"type":"","title":"","detail":"","instance":"","subproblems":[]},"order":"https://acme.zerossl.com/v2/DV90/order/0y9HIDw7Y4vM-OJP0mLB2g","attempt":1,"max_attempts":3}
tutor_local-caddy-1 | {"level":"error","ts":1702905999.2190259,"logger":"tls.obtain","msg":"could not get certificate from issuer","identifier":"data.lms.sharifstar.com","issuer":"acme.zerossl.com-v2-DV90","error":"HTTP 0 - "}
tutor_local-caddy-1 | {"level":"error","ts":1702905999.2191658,"logger":"tls.obtain","msg":"will retry","error":"[data.lms.sharifstar.com] Obtain: [data.lms.sharifstar.com] solving challenge: data.lms.sharifstar.com: [data.lms.sharifstar.com] authorization failed: HTTP 0 - (ca=https://acme.zerossl.com/v2/DV90)","attempt":5,"retrying_in":600,"elapsed":690.325850584,"max_duration":2592000}
tutor_local-cairn-superset-1 | 127.0.0.1 - - [18/Dec/2023:13:26:47 +0000] "GET /health HTTP/1.1" 200 2 "-" "curl/7.74.0"
tutor_local-cairn-superset-worker-beat-1 | [2023-12-18 13:27:00,022: INFO/MainProcess] Scheduler: Sending due task reports.scheduler (reports.scheduler)
tutor_local-cairn-superset-worker-1 | [2023-12-18 13:27:00,061: INFO/MainProcess] Task reports.scheduler[ea94aa28-e9ed-440a-b50c-696852366a3d] received
tutor_local-cairn-superset-worker-1 | [2023-12-18 13:27:00,071: INFO/ForkPoolWorker-1] Task reports.scheduler[ea94aa28-e9ed-440a-b50c-696852366a3d] succeeded in 0.0008318191394209862s: None
Guess it must be a failed attempt to get an ssl certificate, right?
Yes, most definitely. I see that you managed to resolve the issue by yourself? I’m guessing that it was an issue with your DNS records?
Well I tried to get the domain with http and it’s fine. So yes the only problem is https. Guess it must be something with the DNS. By the way, is there any other way of adding the ssl cert? Like using an existing cert?
HTTPS access works for me as well: https://data.lms.sharifstar.com/
Yes it’s working now! Thanks : )