GoogleCloudPlatform / GoogleCloudPlatform/generative-ai

[Bug]: Cloud Run IAP Load Balancer - Streamlit Websocket Issue

Open
#1,086 3 comments 0 reactions 1 assignee Claimed by @lavinigam-gcp View on GitHub
Dominant language
Jupyter Notebook
Stars
17.7k
Forks
4.5k
Avg merge
12h 38m
Merged PRs (30d)
42

Description

### File Name

gemini/sample-apps/gemini-streamlit-cloudrun

### What happened?

My team (@JoshLuxton) and I stood up this sample app in cloud run, IAP and load balancer with the following [instructions/documentation](https://cloud.google.com/vertex-ai/generative-ai/docs/streamlit/streamlit-genai-iap). We believe we followed all the instructions correctly, but we're encountering the following issue with trying to hit the public facing endpoint where the Streamlit app isn't able to complete the web socket connection. The page comes up blank:
![Screenshot 2024-09-13 at 2 59 08 PM](https://github.com/user-attachments/assets/4ffe6cf5-96bb-4d29-b532-b3432336e88f)

And we get the following error on the console output.
Screenshot 2024-09-13 at 3 35 00 PM

Any help understanding this issue is appreciated, and I can provide more context if needed.

### Relevant log output

```shell
main.33cac65c.js:10 WebsocketConnection WebSocket onerror
a @ main.33cac65c.js:10Understand this error
main.33cac65c.js:19 WebSocket connection to 'wss://*********/_stcore/stream' failed:
```

### Code of Conduct

- [X] I agree to follow this project's Code of Conduct

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.