CMS Development

NEdwards
Member

HubSpot Domain behind AWS CloudFront

SOLVE

Our current website is behind an AWS CloudFront distribution because the same domain serves multiple sites.  One of these sites is moving to HubSpot.  We have found and followed the documentation here (https://developers.hubspot.com/docs/cms/developer-reference/reverse-proxy-support) but are having issues at the last confirmation step.  The time changes, the user-agent is right, the accept-language is good, cookie is not blank, protocoal is https, leftmost IP is my IP, but the IP-Determined Location is not right; it shows the CDN POP the origin request is coming from.

 

Results of `/_hcms/diagnostics`: Screen Shot 2021-03-16 at 11.19.13 AM.png

 

0 Upvotes
1 Accepted solution
NEdwards
Solution
Member

HubSpot Domain behind AWS CloudFront

SOLVE

Hi Dennis,

 

No we've moved on and decided to go about the problem from a different direction since this method isn't officially supports/recommended.

View solution in original post

5 Replies 5
robertainslie
HubSpot Employee
HubSpot Employee

HubSpot Domain behind AWS CloudFront

SOLVE

@NEdwards @REE -  While this post is slightly old, this should work now. There was an issue with case sensitivity of headers that is now resolved. You can see that referenced on this post: https://community.hubspot.com/t5/CMS-Development/HS-s-Reverse-Proxy-has-anyone-used-this-in-producti...

The Cloudfront setup should work to show the IP location information of the originating client. I have a setup in AWS that is configured properly that I can privately share if you're interested, just shoot me a DM.

Additionally, I just posted a thread that highlights a few 'lessons learned' that the HubSpot Tech Consulting team has seen regarding reverse proxy setup - https://community.hubspot.com/t5/CMS-Development/Lessons-Learned-from-Setting-up-a-Reverse-Proxy-Wit...

NEdwards
Member

HubSpot Domain behind AWS CloudFront

SOLVE

REE,

 

We were never able to get support from our hubspot support contacts, and were a little turned off running it behind CloudFront because of all the warnings.  We ended up re-designing and migrating the "sub-site" to another domain so that we can host it seperatly behind CloudFront.  This is by no means ideal because it will affect our SEO, but we didn't see much of another option.

0 Upvotes
REE
Participant

HubSpot Domain behind AWS CloudFront

SOLVE

Hi NEdwards,

 

Would you please share the different direction/solution as we are in the exact same situation (and have exhausted all HS support options - none)? We are considering another option, but would appreciate learning from your experience. Please consider emailing me at ruth@csrhub.com. Thanks.

0 Upvotes
NEdwards
Solution
Member

HubSpot Domain behind AWS CloudFront

SOLVE

Hi Dennis,

 

No we've moved on and decided to go about the problem from a different direction since this method isn't officially supports/recommended.

dennisedson
HubSpot Product Team
HubSpot Product Team

HubSpot Domain behind AWS CloudFront

SOLVE

Hello @NEdwards

Not sure how I missed this, but are you still working on this problem?

0 Upvotes