Whatever you do, you do at your own risk. I can only recommend and do not claim 100% of the solution much depends on your environment and other settings. I can not guess. Addition of materials and fixing bugs is welcomed

Not so much useful in my lines, how many attempt to muster in one place all "hacks", which account for to do.
And so that at us at full HTTPS the file robots was available for robots.a txt with the correct Host Directive must be created. And this is no problem, but if you have as in my case closed access via HTTP more than completely, then how to convey to your robots robots.txt .
At the moment, I have not found anything easier than to open access only to the robot.txt on 80 port for this in section preset https for your domain adding the next:

location / {
            location = /robots.txt {
                    rewrite ^ /robots.txt break;
         }
}

Смотрите также: Redirect 301 C http to https and no-www to www

If you helped the article or information was useful. Gratitude should not know borders

Popular tags