https://github.com/randy3k/shiny-cloudrun-demo
Running Shiny app on Google Cloud Run
https://github.com/randy3k/shiny-cloudrun-demo
Last synced: 24 days ago
JSON representation
Running Shiny app on Google Cloud Run
- Host: GitHub
- URL: https://github.com/randy3k/shiny-cloudrun-demo
- Owner: randy3k
- Created: 2020-05-05T07:07:34.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2021-12-09T20:39:57.000Z (over 3 years ago)
- Last Synced: 2025-03-18T02:11:17.326Z (28 days ago)
- Language: R
- Homepage:
- Size: 8.79 KB
- Stars: 35
- Watchers: 3
- Forks: 14
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- jimsghstars - randy3k/shiny-cloudrun-demo - Running Shiny app on Google Cloud Run (R)
README
# Running Shiny app on Google Cloud Run
EDIT: it is probably outdated as Google Cloudrun now supports websocket.
```
PROJECTID=$(gcloud config get-value project)
```Build the image locally and push to Google registry
```
docker build . -t gcr.io/$PROJECTID/shinyrun
# optional, test locally
# docker run --rm -p 8080:8080 gcr.io/$PROJECTID/shinyrun:latest
gcloud auth configure-docker
docker push gcr.io/$PROJECTID/shinyrun
```Alternatively, ultilize Googld Builds to build image
```
gcloud builds submit --tag gcr.io/$PROJECTID/shinyrun
```Deploy to Google Cloud Run
```
gcloud run deploy --image gcr.io/$PROJECTID/shinyrun --platform managed --max-instances 1
# for project with large memory need
# gcloud run deploy --image gcr.io/$PROJECTID/shinyrun --platform managed --max-instances 1 --memory 1G
```