Solved

Url rewritting non www to www and Cloudfront CDN

Posted on 2013-01-30
1
860 Views
Last Modified: 2013-02-03
I'm using managed fusion to rewrite non www to www.

RewriteCond %{HTTP_HOST} ^mysite.com$ [NC]
RewriteRule ^/(.*)$ http://www.mysite.com [R=301,NC,L]

However, this is messing up cloudfront

When I make a request to
mycode.cloudfront.net/images/logo.png

I get redirected to www.mysite.com
When i remove the cond and rule, it works as expected.


The origin in cloudfront is setup as
mysite.com

I'm not sure I understand why this is happening, any suggestions?
0
Comment
Question by:JRockFL
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 29

Accepted Solution

by:
Kumaraswamy R earned 500 total points
ID: 38838328
Hi

bellow url give some idea

Using CloudFront CDN for Sitecore media content

http://herskind.co.uk/blog/2012/04/using-cloudfront-for-sitecore-media-content

IIS URL Rewrite – rewriting non-www to www

http://weblogs.asp.net/owscott/archive/2009/11/27/iis-url-rewrite-rewriting-non-www-to-www.aspx
0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Lots of people ask this question on how to extend the “MembershipProvider” to make use of custom authentication like using existing database or make use of some other way of authentication. Many blogs show you how to extend the membership provider c…
I recently went through the process of creating a Calendar Control of events with the basis of using a database to keep track of the dates that are selectable, one requirement was to have the selected date pop-up in a simple lightbox.  At first this…
This is a high-level webinar that covers the history of enterprise open source database use. It addresses both the advantages companies see in using open source database technologies, as well as the fears and reservations they might have. In this…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

691 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question