Skip to content

Commit

Permalink
follow guide to deploy on gcloud
Browse files Browse the repository at this point in the history
  • Loading branch information
francesconazzaro committed Apr 16, 2021
1 parent 8150a5b commit f3e1c6d
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 2 deletions.
19 changes: 19 additions & 0 deletions .gcloudignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# This file specifies files that are *not* uploaded to Google Cloud Platform
# using gcloud. It follows the same syntax as .gitignore, with the addition of
# "#!include" directives (which insert the entries of the given .gitignore-style
# file at that point).
#
# For more information, run:
# $ gcloud topic gcloudignore
#
.gcloudignore
# If you would like to upload your .git directory, .gitignore file or files
# from your .gitignore file, remove the corresponding line
# below:
.git
.gitignore

# Python pycache:
__pycache__/
# Ignored by the build system
/setup.cfg
11 changes: 11 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
.PHONY: run run-container gcloud-deploy

run:
@streamlit run app.py --server.port=8080 --server.address=0.0.0.0

run-container:
@docker build . -t $APP_NAME
@docker run -p 8080:8080 $APP_NAME

gcloud-deploy:
@gcloud app deploy app.yaml
4 changes: 2 additions & 2 deletions app.yaml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
runtime: python38
entrypoint: streamlit run app.py
runtime: custom
env: flex

0 comments on commit f3e1c6d

Please sign in to comment.