SSL on Maindomain - subdomain to AWS

Hello everyone,

today I successfully installed nextcloud on an AWS EC2 instance and connected the application to a S3 bucket.

Now I am trying to get the SSL running.
I have a main domain with an ssl certificate.
I want to use a subdomain like to forward me the AWS Public DNS (IPv4)

Unfortunatly I keep getting an unauthorized type error when use lets encrypt cmd.
I added the A/AAAA record for the subdomain aswell the main domain, but it doesnt seem to work.

Did somebody came acress the same error and could help me out with the ssl forwarding?

Thanks in advanced

could you post the complete certbot error message? (without your real domain/ip)

i’m developing my playbooks an aws using it worked hundreds of times.

you may try. just follow the readme.

The keywords AWS, EC2 I do not know, are they specific to your provider?

You need to add alternate name entries to your certificate, for and

FYI: AWS | Amazon Elastic Compute Cloud (EC2)

sorry for my late response. This is the error message I get.
Even thought the DNS A/AAAA record is entered correctly, and the SSL certificate is for the main domain and all the subdomains.

Waiting for verification…
Cleaning up challenges
Failed authorization procedure. (http-01): urn:ietf:params:acme:error:unauthorized :: The client lacks sufficient authorization :: Invalid response from [2001:8d8:100f:f000::214]: 204