Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Docs] Rewrite run methods and deployment docs #945

Open
wants to merge 19 commits into
base: main
Choose a base branch
from

Conversation

stichbury
Copy link
Contributor

@stichbury stichbury commented Jan 7, 2025

Description

@stichbury started reorganising and tidying the "Run methods" page, and @antonymilne extended the changes to rewrite much of it from scratch. This was probably the weakest part of our docs before and it's hopefully much improved now.

Reviewers: don't try to look at the diff, just look at the built docs:
https://vizro--945.org.readthedocs.build/en/945/pages/user-guides/run/
https://vizro--945.org.readthedocs.build/en/945/pages/user-guides/deploy/

Major changes:

  • split the run page into two: "How to run your dashboard in development" and "How to deploy your dashboard to production". We don't use the word "launch" any more (although I don't hate the word, so feel free to still say it where it makes sense!)
  • content of the run page is largely the same as before but reorganised
  • deploy page is completely new. We have detailed sections on Hugging Face, Ploomber, Dash Enterprise, plus general guidance on other solutions
  • Ploomber instructions summarise and refer to our new section in their documentation (FYI @edublancas)
  • Hugging Face instructions follow a whole new method that is basically "one click". I have created a new demo dashboard in our gallery for this
  • Updated all our official Vizro demo dashboards on HF to simplify the Dockerfile and use uv

TODO:

Notice

  • I acknowledge and agree that, by checking this box and clicking "Submit Pull Request":

    • I submit this contribution under the Apache 2.0 license and represent that I am entitled to do so on behalf of myself, my employer, or relevant third parties, as applicable.
    • I certify that (a) this contribution is my original creation and / or (b) to the extent it is not my original creation, I am authorized to submit this contribution on behalf of the original creator(s) or their licensees.
    • I certify that the use of this contribution as authorized by the Apache 2.0 license does not violate the intellectual property rights of anyone else.
    • I have not referenced individuals, products or companies in any commits, directly or indirectly.
    • I have not added data or restricted code in any commits, directly or indirectly.

@stichbury stichbury added the Docs 🗒️ Issue for markdown and API documentation label Jan 7, 2025
@stichbury stichbury self-assigned this Jan 7, 2025
@stichbury stichbury requested a review from petar-qb January 7, 2025 10:29
Copy link
Contributor

github-actions bot commented Jan 7, 2025

View the example dashboards of the current commit live on PyCafe ☕ 🚀

Updated on: 2025-01-24 17:32:08 UTC
Commit: b9a5a06

Link: vizro-core/examples/dev/

Link: vizro-core/examples/scratch_dev

Link: vizro-core/examples/visual-vocabulary/

Link: vizro-ai/examples/dashboard_ui/

@stichbury stichbury changed the title [Docs] Add dash enterprise to run/launch/deploy docs for #1402 [DRAFT][Docs] Add dash enterprise to run/launch/deploy docs for #1402 Jan 7, 2025
@stichbury stichbury marked this pull request as draft January 7, 2025 13:10
@stichbury stichbury changed the title [DRAFT][Docs] Add dash enterprise to run/launch/deploy docs for #1402 [DRAFT][Docs] Revise run methods/deployment docs Jan 7, 2025
Copy link
Contributor

@petar-qb petar-qb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Really great refactoring 👍

I have a question: should the Gunicorn section go under deployment? It mentions deployment so naturally would fit better, right?

I agree that the "Gunicorn" section should go under the "Deployment". Great spot!

Also, and maybe related, I am concerned that we aren't that tight about language, or maybe it's my understanding. The file is called run.md and the ToC had the page listed as "Run methods" but we mostly talk about "launching" and then Gunicorn talks about deployment, then there's a section on deployment. Can I get clarity on the difference, or not, in what we mean by "run", "launch" and "deploy" and then I'll run through again and ensure everything is consistent.

I understand the confusion because these terms are quite intertwined here.
So, "run" and "launch" are the same terms that describe running/launching the app locally (for the development purpose).
However, deployment means more like setting-up and running the production-ready app somewhere on the server (not locally).

Also, I like the "Launch the dashboard" title, and also the suggestion to move "Gunicorn" under the "Deployment" section. I guess we should rename the file from run.md -> launch_the_dashboard.md, and align wordings across documents accordingly.

@stichbury
Copy link
Contributor Author

Thanks @petar-qb, that's really helpful feedback!

@antonymilne antonymilne assigned antonymilne and unassigned stichbury Jan 16, 2025
@petar-qb petar-qb self-requested a review January 23, 2025 06:41
@antonymilne antonymilne changed the title [DRAFT][Docs] Revise run methods/deployment docs [Docs] Rewrite run methods and deployment docs Jan 23, 2025
@antonymilne antonymilne marked this pull request as ready for review January 23, 2025 11:10
COPY requirements.txt .
RUN uv pip install --system -r requirements.txt
COPY . .
# (2)!
Copy link
Contributor

@antonymilne antonymilne Jan 23, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wanted to put these on the end of the lines rather than on new lines of their own but unfortunately it's not possible without using mkdocs insiders due to limitations with how comments are handled in Dockerfiles.

Comment on lines 106 to 123
## Dash Enterprise

Since a Vizro app is a Dash app under the hood, they can be deployed to [Dash Enterprise](https://plotly.com/dash/) and accessed in the same way as other Dash apps.

Dash Enterprise helps to deploy and scale production-grade data apps and integrate them with IT infrastructure such as authentication and VPC services. Vizro users may find it suitable for deployment, rapid development environments, and authentication.

Vizro is compatible with the following functionality within Dash Enterprise:

- [App Portal](https://dash.plotly.com/dash-enterprise/portal?de-version=5.5)
- [App Manager](https://plotly.com/dash/app-manager/)
- [Dash App Workspaces](https://plotly.com/dash/workspaces/)
- [App logs and viewer statistics](https://dash.plotly.com/dash-enterprise/logs?de-version=5.5)
- [Centralized data app management](https://plotly.com/dash/centralized-data-app-management/)
- [CI/CD](https://plotly.com/dash/continuous-integration/)
- [Redis](https://plotly.com/dash/big-data-for-python/)
- [Dash Enterprise Authentication](https://plotly.com/dash/authentication/)

Vizro is not currently compatible with the [Dashboard Engine](https://plotly.com/dash/snapshot-engine/) or [Dash Design Kit](https://plotly.com/dash/design-kit/), and cannot produce static reports accessed via the [Snapshot Engine](https://plotly.com/dash/snapshot-engine/).
Copy link

@ndrezn ndrezn Jan 23, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@LiamConnors could you give this a read to see if you have anything you think is worth adding or changing?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Docs 🗒️ Issue for markdown and API documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants