• Resolved Soliman

    (@soliman18eg)


    I created multisite with subdirectory (subfolder). I setup the main site with good success so far but not sure about the subsite (subfolder: https://www.mydomain.com/xyz) its a new setup.
    There is a section for multisite I saw it but it says
    STEP I
    Complete Step I, for each site, on WPAdmin AWS CDN Page
    Site list
    Note: Switch to CDN URL after the CDN status has changes to Deployed.

    STEP II
    CDN DOMAIN / CNAME

    what is the best practice? Should I sue use the same distribution for the main domain? or create a new one for each subdirectory? Keep in mind that will be target different audience and will be different language
    thank you

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author luckychingi

    (@luckychingi)

    Hello @soliman18eg

    On the main admin page of the plugin, you should see a dropdown of all the sub-sites.
    Select the ones you want to use CDN on and hit ‘Create Distribution’

    Are your subsites different websites or same as main website but in a different language?

    In a multisite setup, you should create distribution for each sub-site.

    Thread Starter Soliman

    (@soliman18eg)

    Yes all the subsists belong to the main site but they need to be separate user and separate region.

    It make sense to me the each sub site has its own distribution and own cname (cdn.mydomain.com).
    The question here is so I need to creat different bucket and different aws certificate For Https?

    Plugin Author luckychingi

    (@luckychingi)

    Yes, if you will have to create separate bucket for each site.

    Logically the root domain SSL cert should work on all the subsites but I haven’t tested if a Cloudfront can use the same cert for all distributions.

    Thread Starter Soliman

    (@soliman18eg)

    Thank you for help
    Finally how long you keep answering questions for free ?
    How much are the average donation?

    Thread Starter Soliman

    (@soliman18eg)

    HI I searched a bit and I found this. let me what do you think.
    https://docs.aws.amazon.com/acm/latest/userguide/acm-certificate.html

    “Multiple Domain Names
    Each ACM certificate must include at least one fully qualified domain name (FQDN), and you can add additional names if you want. For example, when you are creating an ACM certificate for https://www.example.com, you can also add the name https://www.example.net if customers can reach your site by using either name. This is also true of bare domains (also known as the zone apex or naked domains). That is, you can request an ACM certificate for https://www.example.com and add the name example.com. For more information, see Request a Public Certificate.
    Wildcard Names
    ACM allows you to use an asterisk (*) in the domain name to create an ACM certificate containing a wildcard name that can protect several sites in the same domain. For example, *.example.com protects https://www.example.com and images.example.com.
    Note
    When you request a wildcard certificate, the asterisk (*) must be in the leftmost position of the domain name and can protect only one subdomain level. For example, *.example.com can protect login.example.com and test.example.com, but it cannot protect test.login.example.com. Also note that *.example.com protects only the subdomains of example.com, it does not protect the bare or apex domain (example.com). However, you can request a certificate that protects a bare or apex domain and its subdomains by specifying multiple domain names in your request. For example, you can request a certificate that protects example.com and *.example.com.”
    Ok I was trying to add subdirectory to the certificate by creating a whole new one adding the subdomain. Appreantly it won’t accepted.
    The reason according to this document “ Wildcard Names
    ACM allows you to use an asterisk (*) in the domain name to create an ACM certificate containing a wildcard name that can protect several sites in the same domain. For example, *.example.com protects https://www.example.com and images.example.com.”
    So
    How can I make sure? Good question isn’t https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-web-testing.html
    If you For example, if your domain name were d111111abcdef8.cloudfront.net and your object were image.jpg, the URL for the link would be:
    https://d111111abcdef8.cloudfront.net/image.jpg.
    If your object is in a folder on your origin server, then the folder must also be included in the URL. For example, if image.jpg were located in the images folder on your origin server, then the URL would be:
    https://d111111abcdef8.cloudfront.net/images/image.jpg
    and when I tested its true. The main domain the certificate and distribution including the main domain..
    all unless the multisites is different domain name here we need to start a whole new setup.
    I would like to hear your feed back about that to see if I figurate out right.

    Plugin Author luckychingi

    (@luckychingi)

    Thanks for the update @soliman18eg

    I try and answer questions as long as I know I have the answers or can help find one ??

    Frankly, I have never checked the avg donation.

    Since your multisite is subfolder based, the certificate should work as described in your last reply.

    You figured it out all right.

    Thanks again ??

    Plugin Author luckychingi

    (@luckychingi)

    Marking this as closed

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘do i need a new distrubtion for each subdirectory ?’ is closed to new replies.