existing acme certs are working for existing sites, certs for new sites cannot be added

Discussion in 'ISPConfig 3 Priority Support' started by radim_h, Jan 4, 2024.

  1. radim_h

    radim_h Member HowtoForge Supporter

    Hello,
    I have one ISPC/Debian12 about 3 months old installation where existing ACME for sites is working and certificates are renewed.
    But there is problem, i cannot add new certificate for new site nor aliasdomain certs are created.
    New dir is not created in /root/.acme.sh, or site added to /root/.acme.sh/site.tld/site.tld.csr.conf
    There is one new task in red color "The following changes are not yet populated to all servers: Update website settings: 1"
    Then it dissapears and site is again without "SSL / Let's Encrypt SSLcertificate" checkboxes checked.
    Nothing appears in /var/log/ispconfig/acme.log ISPConfig is not even trying to install new cert.
    Do you have idea, where to find what could be wrong?
    Regards
    RH
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

  3. radim_h

    radim_h Member HowtoForge Supporter

    Thank you Till, I found this thread in your link earlier
    no error on /usr/local/ispconfig/server/server.sh, no error in log on manual acme.sh OK... debug log OK... it is just not creating certs for the sites

    I have been thinking - disable LE for all sites, delete acme completely install it again and run resync ?
    not sure it will be created automatically for alias sites, there is about 30 of them... also if /.acme.sh/ca/acme-v02.api.letsencrypt.org will be newly created?
     
  4. radim_h

    radim_h Member HowtoForge Supporter

  5. till

    till Super Moderator Staff Member ISPConfig Developer

    As the FAQ mentions, please post the output of server.sh.

    Please do not do that. Just enable let's encrypt checkbox in website after you enabled debug mode, then run server.sh and post the output that you get on the shell.

    Alias domains get added automatically to a cert.
     
  6. radim_h

    radim_h Member HowtoForge Supporter

    Oh, sorry, i'm lame, new site i was trying to add was not pointed to the server .o]. After DNS change new site was created with ACME cert.

    So result: when i add new site, cert is created,
    When i try to add alias domain, i'm getting message
    WARNING - Could not verify domain domain.tld, so excluding it from letsencrypt request.

    When i deleted one of the alias domains and try to add it back, getting same error
    WARNING - Could not verify domain
    and domain cannot be readded

    When i create new site and try to add aliasdomian for that new site, alias domain cert is again not created.

    My on may not be realted
    From my mind only change which i did on the server was changing hostname for whole server, then i forced update and created new cert for server nane
     
  7. till

    till Super Moderator Staff Member ISPConfig Developer

    This means that the domain domain.tld does not point to your server in DNS yet. It does not matter for a acme.sh cert if this is a alias domain, subdomain or website, its just that when accessing this specific domain name, the request does not end up on this server.

    That's not related.


     
  8. radim_h

    radim_h Member HowtoForge Supporter

    no, it does not, because when i create not alias, but regular website, certificate is created for same site alias cert was not created...
    in simple - it is not creating certs for alias pages, it is creating certs just for regular pages, this is my problem...
    special weird problem as usual :D
     
  9. till

    till Super Moderator Staff Member ISPConfig Developer

    Please post the full debug output that you get. And you can try to disable the Let's encrypt check, see step 4 of the FAQ.
     
  10. radim_h

    radim_h Member HowtoForge Supporter

    Hello,
    i do not want to post full log, as this is clients server with adult site and about 40 aliases...

    But here comes the finale...
    when i:
    - add domainalias and check the "Don't add to Let's Encrypt certificate"
    - then uncheck this box in step 2
    SSL cert is created
    it just says " DEBUG [letsencrypt.inc:393] - Verified domain domain.tld should be reachable for letsencrypt." and it is added to the cert chain with no problem..

    Weird, maybe some timeout ??
     
  11. till

    till Super Moderator Staff Member ISPConfig Developer

    The domain is not added to the cert of the site if it's not found in DNS or does not point to the correct server yet. So it's not a timeout, it's just that the domain could not be reached yet, and that's why LE did not add it. So in fact, it did not mattered much what you did as second step, by doing a change, in this case changing this checkbox, and update for the site is run and ISPConfig tried again to add it to the cert, which then succeeded as the domain now pointed to the new server and was reachable in DNS.

    Its important that you always add domains in DNS first and take care they point to the new server before adding them as an alias to a site.
     
  12. radim_h

    radim_h Member HowtoForge Supporter

    Thank you Till.
    I do not want to argue and i appreciate your help. But is not how it seems.
    Both added domains are pointing to server for about a week. There was no DNS change between first "Don't add to Let's Encrypt certificate" adding as alias step , and second step when unchecking this checkbox.

    FYI, there is about 22 aliasdomains (44 certificate names with www variant), it may have some effect..
    I'm happy it works, doesnt matter i have to do i in two steps.
     

Share This Page