Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to request certs for multiple domains? #2

Open
raldone01 opened this issue Apr 11, 2024 · 1 comment
Open

How to request certs for multiple domains? #2

raldone01 opened this issue Apr 11, 2024 · 1 comment

Comments

@raldone01
Copy link

raldone01 commented Apr 11, 2024

Is there a way to get certs for multiple domains?
Preferably in one file.

I would like to replace the following certbot with this plugin:
certbot certonly --agree-tos -n --keep-until-expiring --email 'mail@example.com' --no-redirect --text --cert-name cert -d example.com -d www.example.com -d nextcloud.example.com -d '*.pages.example.com' --authenticator dns-godaddy --dns-godaddy-propagation-seconds 160 --dns-godaddy-credentials /run/secrets/nginx_cerbot_godaddy_credentials --server https://acme-v02.api.letsencrypt.org/directory

I tried adding multiple domains to the domain keyword but it didn't work.
I also added two domain keys to the acme block but then only the last one is used.

Here is my Corefile:

example.com {
    log
    errors
    file /root/example.com.db example.com
    #forward . 8.8.8.8

    tls acme {
        domain example.com
        domain www.example.com # doesn't work
        
        domain example.com www.example.com # doesn't work
        
        email raldone01@gmail.com
        #certpath $HOME/.local/share/certmagic
        # Production endpoint
        #ca https://acme-v02.api.letsencrypt.org/directory
        # Staging endpoint
        ca https://acme-staging-v02.api.letsencrypt.org/directory
    }
}

If this is already possible the documentation could be improved.
Thank you for your work on the plugin.

@raldone01 raldone01 changed the title How to request multiple domains? How to request certs for multiple domains? Apr 11, 2024
@mariuskimmina
Copy link
Owner

Hi @raldone01

I am afraid at the moment this is not possible. I can see that this would be useful tho, I'll add it when I find time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants