Skip to content

Add signed URL setup instructions in README - #736

Merged
fsouza merged 4 commits into
fsouza:mainfrom
toadjaune:add-signed-url-readme
Apr 6, 2022
Merged

Add signed URL setup instructions in README#736
fsouza merged 4 commits into
fsouza:mainfrom
toadjaune:add-signed-url-readme

Conversation

@toadjaune

@toadjaune toadjaune commented Apr 5, 2022

Copy link
Copy Markdown
Contributor

Hi !

First of all, thanks for providing this project ! It proved very useful :)

I found however the documentation on the required setup for use with signed URLs insufficient, and had to dig quite a bit in the code to understand how to make it work.

Here's a minimal doc addition explaining how to do it.

You might want to change the structure, such as adding it out of the docker section instead, including it in code samples, etc ...

Related issues : #631 #537

Closes #631.

@toadjaune

Copy link
Copy Markdown
Contributor Author

Also, I think this way of doing things uses https://github.com/fsouza/fake-gcs-server/blob/main/fakestorage/server.go#L266, I'm not sure how to trigger the next two lines, maybe there's a cleaner way to do it.

@fsouza

fsouza commented Apr 5, 2022

Copy link
Copy Markdown
Owner

Also, I think this way of doing things uses https://github.com/fsouza/fake-gcs-server/blob/main/fakestorage/server.go#L266, I'm not sure how to trigger the next two lines, maybe there's a cleaner way to do it.

The second line (bucketHost) is for when the name of the bucket is specified in the host instead of the path (for example https://bucket.storage.googleapis.com/file.txt vs https://storage.googleapis.com/bucket/file.txt).

The third line is a special case: Google allows us you to name a bucket with a domain and point a CNAME to that bucket (see their docs for more details), so in that case we simply use the bucketName as the host.

@fsouza fsouza left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you very much for contributing!

Comment thread README.md Outdated
Comment thread README.md Outdated
@fsouza
fsouza merged commit 3def301 into fsouza:main Apr 6, 2022
@toadjaune
toadjaune deleted the add-signed-url-readme branch April 21, 2022 20:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants