GCP: Issues with Accessing Public Files from My Backend Bucket

I’m experiencing difficulties with my backend bucket setup in Google Cloud Platform where files are not accessible as expected.

Overview:
I configured a backend bucket on my load balancer and linked it to the path /__/auth/. The bucket contains a file named handler, which should be publicly accessible. However, when I try to access /__/auth/handler, I encounter an error XML stating:

<Error>
    <Code>NoSuchKey</Code>
    <Message>The specified key does not exist.</Message>
</Error>

Details of My Setup:

  • I have created a bucket backend with various caching settings and permissions allowing allUsers to view storage objects.
  • The bucket has a file called handler with type application/octet-stream, and it is marked as public in the GCP console.
  • I have set the appropriate URL mapping for the load balancer directing to /__/auth/*.

I am trying to host Firebase’s authentication files to use for an OAuth redirect, as per Google’s recommendations. Can anyone explain why the bucket backend does not seem to find my files? Also, am I following the correct method for handling OAuth redirects using this configuration?

hmm interesting setup! are you sure the load balancer path mapping is configured correctly for /__/auth/*? sometimes there’s a mismatch between what the lb expects vs actual bucket structure. also curious - did you try accessing the file directly via the bucket’s public url first to rule out bucket-level issues? what does your url map configuration look like exactly?

yeah, could be a path issue. make sure your backend bucket is set to serve from the root and not expecting a subfolder. also, check if the handler file is in a nested directory that doesn’t match the url you’re trying to access.