-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
121 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
MANIFEST_FILES = manifest.json requirements.txt | ||
SOURCE_FILES := src/reedfrost/__init__.py src/reedfrost/app.py | ||
|
||
.PHONY: local deploy clean | ||
|
||
local: | ||
poetry run streamlit run src/reedfrost/app.py | ||
|
||
deploy: $(MANIFEST_FILES) $(SOURCE_FILES) | ||
rsconnect deploy \ | ||
manifest manifest.json \ | ||
--title reedfrost | ||
|
||
manifest.json requirements.txt: $(SOURCE_FILES) | ||
rm -f requirements.txt | ||
rsconnect write-manifest streamlit . \ | ||
$(SOURCE_FILES) \ | ||
--exclude "**" \ | ||
--entrypoint src/reedfrost/app.py \ | ||
--overwrite | ||
|
||
clean: | ||
rm -f $(MANIFEST_FILES) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,16 +14,37 @@ This is a [poetry](https://python-poetry.org/)-enabled Python project: | |
2. [Install poetry](https://python-poetry.org/docs/#installation). | ||
3. Install this package locally with `poetry install`. | ||
|
||
### App | ||
|
||
Run the [Streamlit](https://streamlit.io/) app locally: `poetry run streamlit run src/reedfrost/app.py`. | ||
|
||
### Docs | ||
|
||
Read the [docs online](https://cdcgov.github.io/reedfrost/). | ||
|
||
Documentation is built using [`mkdocs`](https://www.mkdocs.org/). View the documentation locally with `poetry run mkdocs serve`. | ||
|
||
### Local app | ||
|
||
Run the [Streamlit](https://streamlit.io/) app locally with `make local`. | ||
|
||
### Deployed app | ||
|
||
To deploy using [Posit Connect](https://docs.posit.co/connect/user/publishing-cli/): | ||
|
||
- Navigate to your Posit server | ||
- Request to be made a Publisher | ||
- Get an API key | ||
- Add the server: | ||
``` | ||
rsconnect add \ | ||
--server YOUR_SERVER \ | ||
--name NICKNAME \ | ||
--api-key YOUR_API_KEY | ||
``` | ||
You may need to add `--insecure` if you have certificate problems. | ||
- Check which versions of Python are installed on the server: | ||
``` | ||
rsconnect details -n NICKNAME | ||
``` | ||
Ensure that the app is developed against a compatible version of Python. | ||
|
||
## Project admins | ||
|
||
- Scott Olesen <[email protected]> (CDC/IOD/ORR/CFA) | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters