amazon-cloudfront

Is it impossible to use AWS CloudFront for downloading my private image on S3?

匆匆过客 提交于 2019-12-11 12:49:20
问题 I'm making a global iOS App with AWS SDK. And there is a function for users to get image files; only if the requester is a friend of the image files' uploader. For this function, I use AWS S3 for storage service with private access. And I want to use CloudFront for my users to get download files faster. I should set the bucket name for downloading on AWS S3 SDK, but it seems that the CloudFront does not support for this bucket name. Is AWS CloudFront only for public things with url? 回答1: If

AWS CDN create signed url for specific S3 object version

守給你的承諾、 提交于 2019-12-11 11:25:34
问题 Is it possible to create a signed URL for S3 object with particular version. The idea is to have the same image name but different signed url for all the versions of the image. 回答1: Yes. Here are some sample pre-signed URLs that point to a particular object version, with old and new signature format: http://mybucket.s3-ap-southeast-2.amazonaws.com/cat.jpg?versionId=XXX&AWSAccessKeyId=YYY&Expires=1458463363&Signature=ZZZ https://s3-ap-southeast-2.amazonaws.com/mybucket/cat.jpg?versionId=XXX&X

Why CloudFront returns custom error object only when List permission is granted?

℡╲_俬逩灬. 提交于 2019-12-11 11:18:57
问题 I noticed that if the list permission of the bucket is not granted to the public, CloudFront's custom error page (404 not found in my case) always returns 403 forbidden. Once the list permission is granted, a custom 404 image is able to be returned. None of my objects are explicitly marked as publicly readable. But I have given CloudFront origin identity read permission for all objects in the bucket. So I assume, when CloudFront tries to grab the non-existent object, it can't find it; then it

Apache Pig: Extra query parameters from web log

孤街浪徒 提交于 2019-12-11 11:06:45
问题 I am working on analyzing AWS CloudFront access logs. I have the code to load the lines of the file raw_logs2 =LOAD 'file:///home/ec2-user/ENWRZAC68E00M.2011-02-28-18.72jA8eGh' USING PigStorage('\t') AS ( date: chararray, time: chararray, x_edge_location: chararray, sc_bytes: int, c_ip: chararray, cs_method: chararray, cs_host: chararray, cs_uri_stem: chararray, sc_status: chararray, cs_referer: chararray, cs_user_agent:chararray, cs_uri_query: chararray ); Now I am trying to parse the query

Response from Cloudfront from S3 Origin keeps changing CORS Headers

*爱你&永不变心* 提交于 2019-12-11 08:53:55
问题 here is my problem : CORS are set as supposed to be on the S3 : <CORSConfiguration> <CORSRule> <AllowedOrigin>*</AllowedOrigin> <AllowedMethod>GET</AllowedMethod> </CORSRule> </CORSConfiguration> when I try to fetch a file (using jQuery with option CrossDomain = true) from A.example.com -> B.example.com/file.js (works with correct Headers) When I try the same request from another domain : C.dev.example.com -> B.example.com/file.js // (it fails) However for the second example when I look at

Amazon EC2 serves gzipped JavaScript. But Cloudfront does not. Why?

半腔热情 提交于 2019-12-11 07:28:08
问题 I have an Amazon EC2 Web Server instance which serves gzipped content when the Accept-Encoding header is set to gzip . But when I make the same request with the exact same header to a CloudFront CDN with the origin server as my Amazon EC2 instance, it doesn't send back a gzipped response. I also tried creating a new CloudFront distribution(because I thought that the old distribution might have uncompressed response cached) and then making the same request and I still get an uncompressed

Domain not resolving after transferring to AWS

百般思念 提交于 2019-12-11 07:16:52
问题 I transferred my domain ( simplifybits.com) using Route 53 and it successfully transferred. However my domain is not resolving anymore :( This is what my setup looks looks like There are two buckets in S3 simplifybits.com www.simplifybits.com Route 53 configuration simplifybits.com - A s3-website.us-east-2.amazonaws.com. simplifybits.com - NS ns-1069.awsdns-05.org. ns-31.awsdns-03.com. ns-1556.awsdns-02.co.uk. ns-535.awsdns-02.net. simplifybits.com - SOA ns-1069.awsdns-05.org. awsdns

Cloudfront Firefox CORS issues

…衆ロ難τιáo~ 提交于 2019-12-11 06:40:11
问题 We host our assets on S3 using CloudFront. Unfortunately once the asset is cached on CF, the CORS origin header does not change for any subsequent requests. That is problematic, because Firefox won't load fonts if the CORS origin is not an exact match. I'm using the "solution" suggested here adjusting the query for each host. Unfortunately that would require that I provide a different asset set for every possible origin http://example.com http://www.example.com https://example.com https://www

AWS cloudfront - how to serve s3 and EC2 using single cloudfront?

荒凉一梦 提交于 2019-12-11 06:18:27
问题 Is it possible to serve S3 and EC2 using single cloudfront? Steps I followed so far are - Deployed a react app on S3 bucket Deployed a nodejs app on EC2 Both apps are running with their separate public DNS. I am trying to serve both apps using single cloudfront for example - http://dyiqp9sog17kw.cloudfront.net >> it should serve react app, it is working as expected. and http://dyiqp9sog17kw.cloudfront.net/api >> Here I want to run my node app from EC2 but it is throwing Access Denied

aws Lambda to invalidate CloudFront on S3 upload

[亡魂溺海] 提交于 2019-12-11 06:03:49
问题 I have 10-50 files upload at the same time. Lambda triggers an event for every updated file (if file size changed). So instead of invalidating one by one 50x I'd like to run the wildcard “*” character once at the end of the upload. Anyone can shed some light on how to accomplish that? Thanks! 回答1: If I understood your question correctly, your lambda function knows whether CloudFront should invalidate or not but does not know when should that happen exactly. In that case, you could return a