I just ran this today to see if this would work for my needs. It created everything without any issues but I am not able to access the site.
I opted out of having the DNS entry added as this fails due to this already being setup in Route53. So I added the Cloudfront DNS to the DNS record manually. Either way, the Cloudfront DNS does not work (site won't load even when visiting that directly). I thought this may be due to me using a cert so I updated the DNS record for the domain to use the Cloudfront DNS but still nothing.
I am getting the error:
ERROR
The request could not be satisfied.
CloudFront wasn't able to connect to the origin.
When I go to the ELB DNS, the site loads with no CSS applied. Further analyis shows that all requests to any wordpress pathing failed (no 50x or 40x errors). Playing with the Dashboard, I am seeing a 100% Cloudfront error (50x) rate.
It appears there are 2 issues happening here.
ELB is not able to load the assets, can only output text that is rendered
Cloudfront is not able to communicate to ELB (assume SG issue)
I also noted that CloudFront is not configured to pass WordPress cookies so you will have user content mismatch if you use the login system. (although I did see coloudfront with 0 for TTL which I assume is a work-a-round for this issue... I am concerned why this is "best Practice" as this is just a waste of money and passing the cookies seems a better fit) I use this for my WP CloudFront and this works very well: https://aws.amazon.com/blogs/startups/how-to-accelerate-your-wordpress-site-with-amazon-cloudfront/
At this point, I think this is a little much for my needs so I won't be looking further into this. I just wanted to report this as it is not in a working state. I hope this helps. Thanks for all your work, this is really great.
I just ran this today to see if this would work for my needs. It created everything without any issues but I am not able to access the site.
I opted out of having the DNS entry added as this fails due to this already being setup in Route53. So I added the Cloudfront DNS to the DNS record manually. Either way, the Cloudfront DNS does not work (site won't load even when visiting that directly). I thought this may be due to me using a cert so I updated the DNS record for the domain to use the Cloudfront DNS but still nothing.
I am getting the error:
When I go to the ELB DNS, the site loads with no CSS applied. Further analyis shows that all requests to any wordpress pathing failed (no 50x or 40x errors). Playing with the Dashboard, I am seeing a 100% Cloudfront error (50x) rate.
It appears there are 2 issues happening here.
I also noted that CloudFront is not configured to pass WordPress cookies so you will have user content mismatch if you use the login system. (although I did see coloudfront with 0 for TTL which I assume is a work-a-round for this issue... I am concerned why this is "best Practice" as this is just a waste of money and passing the cookies seems a better fit) I use this for my WP CloudFront and this works very well: https://aws.amazon.com/blogs/startups/how-to-accelerate-your-wordpress-site-with-amazon-cloudfront/
At this point, I think this is a little much for my needs so I won't be looking further into this. I just wanted to report this as it is not in a working state. I hope this helps. Thanks for all your work, this is really great.