[GH-ISSUE #724] Getting a 404 with signed urls for GET call #123

Closed
opened 2026-03-03 12:08:30 +03:00 by kerem · 1 comment
Owner

Originally created by @jasonford on GitHub (Mar 21, 2022).
Original GitHub issue: https://github.com/fsouza/fake-gcs-server/issues/724

Thanks for the great software! I might be missing something basic, but I've given it a good search and have come up dry.

I'm generating a signed URL for a read action with the @google-cloud/storage npm module and receiving URLs of the form (default host manually swapped to point to my locally running container):

http://10.0.1.1:4443/development-bucket/3f443741-70a6-11ec-afaf-6b31b4af5cd3?GoogleAccessId=development%40example.com&Expires=1647845172&Signature=...signature...

I've started the docker container like so:

docker run -d --name fake-gcs-server -p 4443:4443 fsouza/fake-gcs-server -scheme http -external-url http://10.0.1.1:4443

All GET calls to the above URL get a 404.

As a sanity check I made sure that GET calls with the format http://10.0.1.1:4443/storage/v1/b/development-bucket/o/3f443741-70a6-11ec-afaf-6b31b4af5cd3 work just fine.

Is the signed URL format I'm getting from the nodejs sdk not supported? I found some resolved issues that seem to indicate otherwise, but I haven't been able to make this GET request work.

Originally created by @jasonford on GitHub (Mar 21, 2022). Original GitHub issue: https://github.com/fsouza/fake-gcs-server/issues/724 Thanks for the great software! I might be missing something basic, but I've given it a good search and have come up dry. I'm generating a signed URL for a read action with the ```@google-cloud/storage``` npm module and receiving URLs of the form (default host manually swapped to point to my locally running container): ``` http://10.0.1.1:4443/development-bucket/3f443741-70a6-11ec-afaf-6b31b4af5cd3?GoogleAccessId=development%40example.com&Expires=1647845172&Signature=...signature... ``` I've started the docker container like so: ``` docker run -d --name fake-gcs-server -p 4443:4443 fsouza/fake-gcs-server -scheme http -external-url http://10.0.1.1:4443 ``` All GET calls to the above URL get a 404. As a sanity check I made sure that GET calls with the format ```http://10.0.1.1:4443/storage/v1/b/development-bucket/o/3f443741-70a6-11ec-afaf-6b31b4af5cd3``` work just fine. Is the signed URL format I'm getting from the nodejs sdk not supported? I found some resolved issues that seem to indicate otherwise, but I haven't been able to make this GET request work.
kerem closed this issue 2026-03-03 12:08:30 +03:00
Author
Owner

@jasonford commented on GitHub (Mar 21, 2022):

Didn't find it documented, but poking around in the code gave me a hint that what I needed was to set the "publicHost" option.

Now I run my docker container with:

docker run -d --name fake-gcs-server -p 4443:4443 fsouza/fake-gcs-server -scheme http -external-url http://10.0.1.1:4443 -public-host 10.0.1.1:4443

and all is well.

Thanks again for the great software!

<!-- gh-comment-id:1073542798 --> @jasonford commented on GitHub (Mar 21, 2022): Didn't find it documented, but poking around in the code gave me a hint that what I needed was to set the "publicHost" option. Now I run my docker container with: ``` docker run -d --name fake-gcs-server -p 4443:4443 fsouza/fake-gcs-server -scheme http -external-url http://10.0.1.1:4443 -public-host 10.0.1.1:4443 ``` and all is well. Thanks again for the great software!
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/fake-gcs-server#123
No description provided.