Does this work for you? For me not. I tried that. The second domain would then direct to the YH-admin as my website (dokuwiki) is installed on the first domain. So, the Redirect app seems to be the only option, at least in my case.
@TheNomad11 this is a support request, moved to its proper section.
Please provide all necessary information (type of server, YunoHost version). Include your Diagnosis report, that’s important to check DNS.
As stated above, if you need to expose both my-yunohost-domain.com and www.my-yunohost-domain.com to the Internet, you need to register both of them as domains in your webadmin. Then you need to make sure the DNS records are correct (CNAME may not be enough,) before generating Let’s Encrypt certificates for both domains.
What you do with them afterwards is up to you. You can definitely setup a Redirect app to redirect from one to the other.
Thanks! @tituspijean Maybe this info could be added to the documentation here? Certificate | Yunohost Documentation I suppose this would be useful for many users. Not everybody might be aware of the extra steps needed for making both www and non-www work?