[✅Solved] Error renew certifcates (Let's Encrypt)

Hello,

I got error when I (or the cron job) want to renew Let’s Encrypt certs (or install a new one for a new domain) :

4773 ERROR Wrote file to /tmp/acme-challenge-public/_KZySkFPWPDLvo33w5yBvM_LOfiYbMs6_TZAOnjPbD4, but couldn't download http://grafana.domain.fr/.well-known/acme
-challenge/_KZySkFPWPDLvo33w5yBvM_LOfiYbMs6_TZAOnjPbD4: hostname 'grafana.domain.fr' doesn't match 'pfsense.domain.fr'
4784 ERROR Could not sign the new certificate

Full log here : https://paste.yunohost.org/woyamehicu.sql

When I do the same witth --no-checks option it works. So I assume that my setup is causing trouble with the check system… Should I provide logs for diagnosis or something else ?

My yunohost server is a VM on Proxmox. The public ip is on another VM with Pfsense which NAT only needed ports to the Yunohost VM on a private IP address. The Yunohost VM has only a priavte IP address.

yunohost:
  repo: stable
  version: 4.0.8
yunohost-admin:
  repo: stable
  version: 4.0.4
moulinette:
  repo: stable
  version: 4.0.3
ssowat:
  repo: stable
  version: 4.0.4.1

Thanks in advance for your help !

Bonjour,

Tout d’abord merci pour ton message.

Si je comprends bien, ton Pfsense est placé en coupure devant ton Yunohost.

Si tu n’utilises pas la fonction reverse proxy de ton Pfsense, es-tu bien sûr que les ports nécessaires sont bien ouverts et redirigent correctement vers ton Yunohost ? (notamment le port 80).

Ta config ressemble-t-elle à celle-ci ? https://blog.zwindler.fr/2020/03/02/deploiement-de-proxmox-ve-6-pfsense-sur-un-serveur-dedie/

Bien à toi.
Sangokuss

Bonjour @Sango,

Merci pour ta réponse. Oui ça ressemble à ce qui est proposé dans ce tuto.
Je n’utilise pas de reverse proxy car je n’ai pas trouvé le temps d’apprendre à le mettre en place. J’ai donc fait du NAT 1:1 sur les ports nécessaires à Yunohost, le 80 et le 443 arrivent effectivement bien sur le VM yunohost. D’ailleurs le renouvellement fonctionne en désactivant les vérifications (option --no-checks)

Merci,
Nathanaël

Ok, par hasard, ton Proxmox, il est chez toi derrière une box ou chez un hébergeur ?
Parce que tant que j’avais la Livebox, idem, le --no-checks était nécessaire (hairpining de la Livebox…).

Le proxmox il chez OVH ( enfin so you start), en datacenter. Je ne connais pas le hairpinning, mais après lecture de cette page https://fr.wikipedia.org/wiki/Hairpinning je vois ce dont il s’agit. Je vais essayer de regarder dans cette direction. Merci.


Edit : hairpining was the problem, thanks for your help!
Links to help other peolple: https://docs.netgate.com/pfsense/en/latest/recipes/port-forwards-from-local-networks.html or http://geekandmore.fr/pfsense-nat-reflection/ in french

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.