{"id":533,"date":"2020-10-10T10:45:42","date_gmt":"2020-10-10T15:45:42","guid":{"rendered":"http:\/\/nukeitmike.com\/blog\/?p=532"},"modified":"2020-10-10T10:45:42","modified_gmt":"2020-10-10T15:45:42","slug":"redirect-http-to-https-using-azure-cdn","status":"publish","type":"post","link":"https:\/\/blog.nukeitmike.com\/index.php\/2020\/10\/10\/redirect-http-to-https-using-azure-cdn\/","title":{"rendered":"Redirect Http to Https using Azure CDN"},"content":{"rendered":"<p>In my recent efforts to move my one page, static content website, I have had a few challenges.&#160; First let me say, those challenges were most certainly due to my ignorance, and not due to the technology in use.&#160; Also, some of my issues are related to trying to make a simple task more complicated than it needs to be (for learning purposes, not for contrariness).<\/p>\n<p>First, it is really easy to setup a static website using an Azure Storage Account.&#160; It really can be done in just a few minutes.&#160; If you don\u2019t care about the URL used to access it, the process can be done in a matter of minutes.<\/p>\n<p>So, to make it take longer, and be more complicated, I first set it to require HTTPS.&#160; Then, I wanted to use my own domain name.&#160; Then I didn\u2019t want to have to put in \u2018www\u2019 at the beginning, and lastly, I wanted to be able to get to it without remembering to type https at the beginning of the URL.<\/p>\n<p>There are many tutorials and walk throughs on how to do all of this, so I am just going to point out the thing I didn\u2019t realize until the end.&#160; The CDN endpoint has a \u2018Rules Engine\u2019.&#160; You can set some complicated rules, but the one I needed was very simple.&#160; If the request comes in as HTTP, redirect to HTTPS.&#160; Easy, and it worked the first time.&#160; How about that?<\/p>\n<p><a href=\"https:\/\/i0.wp.com\/blog.nukeitmike.com\/wp-content\/uploads\/2020\/10\/image-18.png?ssl=1\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" title=\"image\" style=\"margin: 0px; display: inline; background-image: none;\" border=\"0\" alt=\"image\" src=\"https:\/\/i0.wp.com\/blog.nukeitmike.com\/wp-content\/uploads\/2020\/10\/image_thumb-18.png?resize=244%2C96&#038;ssl=1\" width=\"244\" height=\"96\" \/><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In my recent efforts to move my one page, static content website, I have had a few challenges.&#160; First let me say, those challenges were most certainly due to my ignorance, and not due to the technology in use.&#160; Also, some of my issues are related to trying to make a simple task more complicated&hellip; <a class=\"more-link\" href=\"https:\/\/blog.nukeitmike.com\/index.php\/2020\/10\/10\/redirect-http-to-https-using-azure-cdn\/\">Continue reading <span class=\"screen-reader-text\">Redirect Http to Https using Azure CDN<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"advanced_seo_description":"","jetpack_seo_html_title":"","jetpack_seo_noindex":false,"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[2,37],"tags":[52,58,100,146,192],"class_list":["post-533","post","type-post","status-publish","format-standard","hentry","category-azure","category-web-stuff","tag-azure","tag-cdn","tag-https","tag-redirects","tag-web-stuff","entry"],"jetpack_featured_media_url":"","jetpack-related-posts":[],"jetpack_likes_enabled":true,"jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/pcW544-8B","_links":{"self":[{"href":"https:\/\/blog.nukeitmike.com\/index.php\/wp-json\/wp\/v2\/posts\/533","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.nukeitmike.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.nukeitmike.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.nukeitmike.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.nukeitmike.com\/index.php\/wp-json\/wp\/v2\/comments?post=533"}],"version-history":[{"count":0,"href":"https:\/\/blog.nukeitmike.com\/index.php\/wp-json\/wp\/v2\/posts\/533\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.nukeitmike.com\/index.php\/wp-json\/wp\/v2\/media?parent=533"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.nukeitmike.com\/index.php\/wp-json\/wp\/v2\/categories?post=533"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.nukeitmike.com\/index.php\/wp-json\/wp\/v2\/tags?post=533"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}