Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(cloudfront.distribution): (No way to set the Origin access to Origin access control settings (recommended)) #27802

Closed
2 tasks
aramatev opened this issue Nov 1, 2023 · 2 comments
Labels
@aws-cdk/aws-cloudfront Related to Amazon CloudFront closed-for-staleness This issue was automatically closed because it hadn't received any attention in a while. feature-request A feature should be added or improved. p2 response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days.

Comments

@aramatev
Copy link

aramatev commented Nov 1, 2023

Describe the feature

in python aws cdk, there is no way to create Origin access control setting, which is the recommended way. Furthermore when you go to create Distribution there is no way to set the origin access to AOC, the only IOrigin I see is AOI, which also does not work cloudfront.OriginAccessIdentity(). So currently there is no way to make Cloudfront to s3 website work without getting 403 forbidden error.

See, https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/private-content-restricting-access-to-s3.html#private-content-oac-permission-to-access-s3

You can use the legacy way the cloudfront.CloudFrontWebDistribution() way, but it is deprecated and we're told to use Distribution. So please make it work.

Use Case

It seems like we're missing a recommended way to set S3 origin source in cloudfront distribution.

Proposed Solution

I think this is simply not coded and needs to be

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

CDK version used

aws-cdk-lib==2.99.1

Environment details (OS name and version, etc.)

macos, node v20.8.0, python 3.9.13

@aramatev aramatev added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Nov 1, 2023
@github-actions github-actions bot added the @aws-cdk/aws-cloudfront Related to Amazon CloudFront label Nov 1, 2023
@pahud
Copy link
Contributor

pahud commented Nov 10, 2023

I guess this is related to #21771 ?

@pahud pahud added response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days. p2 and removed needs-triage This issue or PR still needs to be triaged. labels Nov 10, 2023
Copy link

This issue has not received a response in a while. If you want to keep this issue open, please leave a comment below and auto-close will be canceled.

@github-actions github-actions bot added closing-soon This issue will automatically close in 4 days unless further comments are made. closed-for-staleness This issue was automatically closed because it hadn't received any attention in a while. and removed closing-soon This issue will automatically close in 4 days unless further comments are made. labels Nov 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/aws-cloudfront Related to Amazon CloudFront closed-for-staleness This issue was automatically closed because it hadn't received any attention in a while. feature-request A feature should be added or improved. p2 response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days.
Projects
None yet
Development

No branches or pull requests

2 participants