I'm looking to have one nginx host file which handles domain.tld and www.domain.tld with and without https and redirects all of them to use https and www so any visitor would end up at https www.domain.tld
I've tried various options and one of these 4 options was always incorrect.
My best lead so far is this advice I got: https://gist.github.com/bjornjohansen/b5a763a57a460edac47c8560502f6400 - does that look like hte best solution?
If it does could someone help me with what would go in the 2nd server block?
here is my real vhost config: http://pastebin.com/fYq2CjLf
any help is much appreciated, been struggling with this all day.
I've tried various options and one of these 4 options was always incorrect.
My best lead so far is this advice I got: https://gist.github.com/bjornjohansen/b5a763a57a460edac47c8560502f6400 - does that look like hte best solution?
If it does could someone help me with what would go in the 2nd server block?
here is my real vhost config: http://pastebin.com/fYq2CjLf
any help is much appreciated, been struggling with this all day.