nanek / ghost-s3-compat

Read and write images from S3 in the Ghost blogging platfrom
Other
56 stars 18 forks source link

Asset host is not working #4

Closed probus closed 8 years ago

probus commented 8 years ago

Setting assetHost in the config doesn't seem to have any effect.

JuanCaicedo commented 8 years ago

I'm actually not sure how the assetHost works, it was part of the original code that we forked and I've never used that feature. Could you describe how you're trying to use it?

probus commented 8 years ago

I’m might not be using it as it was originally intended, but I use it to simply rewrite the url to my cdn (cloudfront) domain.

If I put assetHost: 'https://mycdndomain.com/' in the settings and upload an image from the editor, the resulting link I get should be https://mycdndomain.com/.../image.jpg instead of https://mybucket.s3.amazonaws.com/.../image.jpg.

frankhinek commented 8 years ago

@JuanCaicedo, the assetHost feature was removed in your initial commit, but is still listed in the README. Since all references to assetHost were taken out you should probably update the README unless you plan to add the feature back.

For me this is a key feature which enables me to use a CDN as @probus is looking to do as well.

frankhinek commented 8 years ago

This is fixed in the fork I just published that handles all current AWS regions using the path-url style of accessing S3 buckets.

JuanCaicedo commented 8 years ago

Ah I see. My apologies @probus I hadn't realized this was still in the readme, and by doing that we were implying it was a supported feature! @frankhinek thanks for your work showing how to fix this. I'll push a PR and version soon

JuanCaicedo commented 8 years ago

This will be addressed in the above PR.

@frankhinek I chose not to bring over most of your changes to the readme, particularly the installation docs. We specifically changed them by request from the Ghost founder in #5, so I feel confident about leaving them.

JuanCaicedo commented 8 years ago

Version 2.0.0 is published to npm now