|
1 | | -# Custom Studios Examples |
| 1 | +# QuPath KasmVNC Studio Environment |
2 | 2 |
|
3 | | -This repository contains example Dockerfiles and configurations for custom Seqera Studio applications. Each example demonstrates how to create and deploy different types of interactive applications in Seqera Studios. |
| 3 | +This branch contains the Seqera Studios configuration for running [QuPath](https://qupath.github.io/) with [KasmVNC](https://kasmweb.com/kasmvnc), making the QuPath desktop available through a browser in Seqera Platform. |
4 | 4 |
|
5 | | -## Available Examples |
| 5 | +> This is a branch of the [custom-studios-examples](https://github.com/seqeralabs/custom-studios-examples) repository. Each branch contains a different custom Studio configuration. See the `master` branch for an overview of all available Studios. |
6 | 6 |
|
7 | | -- [Marimo](marimo/README.md) - A reactive Python notebook environment |
8 | | -- [CellxGene](cellxgene/README.md) - Interactive single-cell data visualization |
9 | | -- [Streamlit](streamlit/README.md) - MultiQC visualization using Streamlit |
10 | | -- [Shiny](shiny-simple-example/README.md) - Interactive data visualization with R Shiny |
11 | | -- [TTYD](ttyd/README.md) - Interactive web-based terminal with bioinformatics tools |
| 7 | +## Quick Start |
12 | 8 |
|
13 | | -## Prerequisites |
| 9 | +### Add from Git Repository |
14 | 10 |
|
15 | | -All examples in this repository require: |
16 | | -- [Docker](https://www.docker.com/) installed |
17 | | -- [Wave](https://docs.seqera.io/platform-cloud/wave/) configured in your Seqera Platform workspace |
18 | | -- Access to a container registry (public or Amazon ECR) for pushing your images |
| 11 | +1. Navigate to **Studios** > **Add Studio** in your Seqera Platform workspace |
| 12 | +2. Select **Git repository** as the source |
| 13 | +3. Enter the repository URL: `https://github.com/seqeralabs/custom-studios-examples` |
| 14 | +4. Select branch: `kasmvnc-qupath` |
| 15 | +5. Select your compute environment |
| 16 | +6. Click **Add** then **Start** |
19 | 17 |
|
20 | | -## Common Features |
| 18 | +### Alternative: Use Pre-built Image |
21 | 19 |
|
22 | | -All examples in this repository: |
23 | | -- Are compatible with both local Docker testing and Seqera Studios |
24 | | -- Use the required Seqera base image and connect-client |
25 | | -- Include detailed setup and usage instructions |
26 | | -- Support data mounting via datalinks in Studios |
27 | | -- Are built for linux/amd64 platform compatibility |
28 | | -- Use multi-stage builds to include the connect-client |
29 | | -- Follow consistent container best practices |
| 20 | +``` |
| 21 | +ghcr.io/seqeralabs/custom-studios-examples/kasmvnc-qupath:latest |
| 22 | +``` |
30 | 23 |
|
31 | | -## Deploying to Seqera Studios |
| 24 | +### Alternative: Build with Wave CLI |
32 | 25 |
|
33 | | -All examples follow the same deployment process: |
| 26 | +```bash |
| 27 | +wave -f .seqera/Dockerfile --context .seqera --platform linux/amd64 --await --tower-token "$TOWER_ACCESS_TOKEN" |
| 28 | +``` |
34 | 29 |
|
35 | | -1. Select the **Studios** tab in your workspace |
36 | | -2. Click **Add Studio** |
37 | | -3. In the **General config** section: |
38 | | - - Select **Prebuilt container image** as the container template |
39 | | - - Enter your container image URI (e.g., `cr.seqera.io/scidev/your-example`) |
40 | | - - Set a **Studio name** and optional **Description** |
41 | | -4. Configure compute resources in the **Compute and Data** section: |
42 | | - - Select your compute environment |
43 | | - - Adjust CPU, GPU, and memory allocations as needed |
44 | | - - Mount any required data using the **Mount data** option |
45 | | - - Configure environment variables if the example supports them (see [Environment Variables](#environment-variables) section) |
46 | | -5. Review the configuration in the **Summary** section |
47 | | -6. Click **Add and start** to create and launch the Studio |
| 30 | +## Features |
48 | 31 |
|
49 | | -## Environment Variables |
| 32 | +- QuPath 0.6.0 bioimage analysis desktop |
| 33 | +- Browser access through LinuxServer.io KasmVNC |
| 34 | +- Single-app mode that launches QuPath directly |
| 35 | +- KasmVNC WebP, quality, frame-rate, and thread tuning for interactive use |
| 36 | +- Compatible with Seqera Studios custom environments and Data Link mounts |
50 | 37 |
|
51 | | -Some examples support environment variable configuration to customize data paths and application settings without modifying the container image. This makes those examples more flexible and reusable across different datasets and configurations. |
| 38 | +> **Note:** QuPath is x86_64 only. Build and run this Studio as `linux/amd64`. |
52 | 39 |
|
53 | | -### Examples with Environment Variables |
| 40 | +## Docker Image |
54 | 41 |
|
55 | | -Only the following examples support environment variable configuration: |
56 | | -- **CellxGene**: `DATASET_FILE`, `DATASET_TITLE` - Configure dataset path and display title |
57 | | -- **Shiny**: `DATA_PATH` - Configure data file path with automatic cloud storage path conversion |
| 42 | +The container image is available at: |
58 | 43 |
|
59 | | -### Examples without Environment Variables |
| 44 | +``` |
| 45 | +ghcr.io/seqeralabs/custom-studios-examples/kasmvnc-qupath:latest |
| 46 | +``` |
60 | 47 |
|
61 | | -These examples work with their default configurations and don't require environment variable setup: |
62 | | -- **Marimo**: Interactive Python notebook environment |
63 | | -- **Streamlit**: MultiQC visualization with web-based data loading interface |
64 | | -- **TTYD**: Web-based terminal with pre-installed bioinformatics tools |
| 48 | +## Local Testing |
65 | 49 |
|
66 | | -### Using Environment Variables in Seqera Studios |
| 50 | +```bash |
| 51 | +cd .seqera |
| 52 | +docker build --platform=linux/amd64 --build-arg CONNECT_CLIENT_VERSION=0.9 -t kasmvnc-qupath . |
| 53 | +docker run --rm --platform linux/amd64 --shm-size=2g -p 6901:6901 --entrypoint /init kasmvnc-qupath |
| 54 | +``` |
67 | 55 |
|
68 | | -When deploying to Seqera Studios, you can configure environment variables in the **Compute and Data** section: |
69 | | -1. Expand the **Environment variables** section |
70 | | -2. Add key-value pairs for the variables you want to customize |
71 | | -3. The application will use these values instead of the defaults |
| 56 | +QuPath will be available at http://localhost:6901. |
72 | 57 |
|
73 | | -## Documentation |
| 58 | +## Configuration |
74 | 59 |
|
75 | | -- [Official documentation on building custom studio environments](https://docs.seqera.io/platform-cloud/studios/custom-envs#custom-containers) |
76 | | -- Each example's README contains specific instructions for: |
77 | | - - Building and testing locally |
78 | | - - Required dependencies and configurations |
79 | | - - Example-specific features and usage |
80 | | - - Data format requirements |
81 | | - - Customization options |
| 60 | +| Variable | Default | Description | |
| 61 | +|----------|---------|-------------| |
| 62 | +| `CONNECT_TOOL_PORT` | Set by platform | KasmVNC web port in Seqera Studios | |
| 63 | +| `CUSTOM_PORT` | `CONNECT_TOOL_PORT` or `6901` | KasmVNC web port used by the base image | |
82 | 64 |
|
83 | | -## Contributing |
| 65 | +## References |
84 | 66 |
|
85 | | -Feel free to contribute new examples or improvements to existing ones. Each example should: |
86 | | -- Follow the established README structure |
87 | | -- Include comprehensive documentation |
88 | | -- Maintain consistency with common features |
89 | | -- Provide clear prerequisites and deployment instructions |
90 | | -- Include example data or clear data requirements |
91 | | - |
92 | | -<!-- TODO Add a link to the blog post --> |
| 67 | +- [Seqera Studios: Custom Environments](https://docs.seqera.io/platform-cloud/studios/custom-envs) |
| 68 | +- [Seqera Studios: Add from Git Repository](https://docs.seqera.io/platform-cloud/studios/add-studio-git-repo) |
| 69 | +- [QuPath Documentation](https://qupath.readthedocs.io/) |
| 70 | +- [KasmVNC Documentation](https://kasmweb.com/kasmvnc) |
0 commit comments