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

Add CloudFront support #2

Closed
rscottbailey opened this issue Dec 10, 2019 · 3 comments · May be fixed by #3
Closed

Add CloudFront support #2

rscottbailey opened this issue Dec 10, 2019 · 3 comments · May be fixed by #3

Comments

@rscottbailey
Copy link

I'm working in an environment where I want to front my bucket (on the consumer side) with a CloudFront distribution. (off topic: this is so I can implement basic authentication with an edge lambda)

At present, generated metadata is unusable because all URLs are absolute and are created using the bucket's FQDN, which isn't accessible. Some options:

  1. Make URLs relative (so they are insensitive to the base URL of the repository)
  2. Add --url https://my-stupid-repo.com switch that allows the URL to be overridden; I actually have implemented this and it's pretty straightforward -- but it's slightly annoying to have to specify both the bucket name and the FQDN on the command line
  3. Add --distribution XYZZYWHATEVER switch (mutually exclusive with --bucket) that specifies the CloudFront distribution identifier (at which point stick can look up both the bucket name and the distribution FQDN)

Thanks for your responsiveness,
Scott

@brandond
Copy link
Owner

Does 6df1a63 do what you need?

@brandond
Copy link
Owner

This should also allow it to work with stuff like the new S3 Access Points feature where the bucket can have multiple aliases.

@brandond
Copy link
Owner

brandond commented Dec 11, 2019

FYI, I was originally inspired to write stick after using https://github.com/novemberfiveco/s3pypi which was designed around using CloudFront. I wasn't quite happy with how it worked and wanted to change it in a few keys so I just started over from scratch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants