1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Handing 15,000+ SSL certs and nginx configuration

Discussion in 'Nginx' started by Jeff1, Oct 21, 2016.

  1. #1
    Hello All,

    I am running an application that has about 200,000 subdomains and 15,000 custom domains. Each subdomain belongs to a customer and they have an ability to white label my platform by using their own ‘custom domains'
    I currently have only 1 nginx configuration file to serve all of these domains. I make use of $http_name variable to dynamically define my websites within single nginx virtual host config but I’d like to implement SSL certificate on all of them.

    200,000 subdomains are easy because I can get away with couple of lines of code with a wildcard certificate.

    My problem is custom domains. These 15,000 unique domains requires SSL cert and I implemented Let’s encrypt to generate certificate for all of them. It works properly so far.

    Here is my question:

    My understanding is that I cannot use variables in file paths. Therefore, to be able to point 15k domain to proper SSL cert, I need to create 15,000 nginx configuration. It’s going to be very hard to manage. What can I do to overcome this problem? Is there any other easy way?
    Jeff1, Oct 21, 2016 IP
  2. tonicc

    tonicc Active Member

    Likes Received:
    Best Answers:
    Trophy Points:

    Instead of using Nginx, you could try Caddy server it comes with "Automatic Https" provided by let's encrypts but you don't need to configure every subdomain ;)

    tonicc, Nov 24, 2016 IP