EDIT: Thanks everyone for your time and responses. To break as little as possible attempting to fix this I’ve opted to go with ZeroSSL’s DNS process to acquire a new cert. I wish I could use this process for all of my certs as it was very quick and easy. Now I just have to figure out the error message lemmy is throwing about not being able to run scripts.

Thank you all for your time sincerely. I understand a lot more than I did last night.


Original Post

As the title says I’m unable to renew a cert on a self-hosted lemmy instance. A friend of mine just passed away and he had his hands all up in this and had it working like magic. I’m not an idiot and have done a ton of the legwork to get our server running and working - but lemmy specifically required a bit of fadanglin’ to get working correctly. Unfortunately he’s not here to ask for help, so I’m turning to you guys. I haven’t had a problem with any of my other software such as nextcloud or pixelfed but for some reason lemmy just refuses to cooperate. I’m using acme.sh to renew the cert because that’s what my buddy was using when he had set this all up. I’m running apache2 on a bare metal ubuntu server.

Here’s my httpd-ssl.conf:

https://pastebin.com/YehfTPNV

Here’s some recent output from my acme.sh/acme.log:

https://pastebin.com/PESVVNg4

Here’s the terminal read out and what I’m attempting to execute:

https://pastebin.com/jfHfiaE0

If you can make any suggestions at all on what I might be missing or what may be configured incorrectly I’d greatly appreciate a nudge in the right direction as I’m ripping my hair out.

Thank you kindly for your time.

  • johannes@lemmy.jhjacobs.nl
    link
    fedilink
    English
    arrow-up
    5
    ·
    18 hours ago

    I’m really surprised noone mentioned Caddy which handles all the SSL business for you. Not to mention an easier config :)

    • Sol 6 VI StatCmd@lemmy.worldOP
      link
      fedilink
      English
      arrow-up
      2
      ·
      2 hours ago

      How hard would it be to switch in your experience… I’d love something this simple. Nervous to tear stuff down though.

      • johannes@lemmy.jhjacobs.nl
        link
        fedilink
        English
        arrow-up
        2
        ·
        edit-2
        2 hours ago

        I dont think its hard :)

        Can you post your apache config?

        Ive been so long on Caddy i havent touched Apache or nginx for ages. But i’m pretty sure i or someone else can help you convert your config :)

        • Sol 6 VI StatCmd@lemmy.worldOP
          link
          fedilink
          English
          arrow-up
          2
          ·
          2 hours ago

          I appreciate the offer. If I get stuck I’ll dump it. If it’s as straight forward as everyone says I should be able to pull it off it looks so easy. Don’t want to make others do my work for me unduly.

          • johannes@lemmy.jhjacobs.nl
            link
            fedilink
            English
            arrow-up
            2
            ·
            edit-2
            1 hour ago

            Oh my god… i completely overlooked the config in your original message!!

            Un any case, look at this: https://join-lemmy.org/docs/administration/caddy.html

            Someone done the work, and they would be glad if you made use of it :)

            And if you start with: lemmy.domain.tld:81 {

            You can even have it run on a different port, so you can test it without risking your apache config.

            • Sol 6 VI StatCmd@lemmy.worldOP
              link
              fedilink
              English
              arrow-up
              1
              ·
              12 minutes ago

              Only thing I’m having trouble with so far is handling a line like this > <FilesMatch \.php$> # Apache 2.4.10+ can proxy to unix socket SetHandler "proxy:unix:///run/php74-fpm.sock|fcgi://localhost/" </FilesMatch> Not really sure how caddy handles this.

    • Swarfega@lemm.ee
      link
      fedilink
      English
      arrow-up
      3
      ·
      edit-2
      15 hours ago

      Caddy is awesome! I originally went for nginx proxy manager to manage my certs as it has a GUI. However, despite being text based, Caddy is so even easier to configure…

              email myemail@mydomain.net
      }
      
      jellyfin.mydomain.net {
              reverse_proxy 192.168.0.1:8096
      }```
      
      
      That's all there is to it. Caddy does the heavy lifting.
      • Rogue@feddit.uk
        link
        fedilink
        English
        arrow-up
        3
        ·
        13 hours ago

        I don’t think you even need to configure the email.

        If I recall correctly emails are optional for Let’s Encrypt but Caddy are partnered with ZeroSSL who do require emails so you’re encouraged to provide one.