Skip to content

Commit

Permalink
wip schema
Browse files Browse the repository at this point in the history
  • Loading branch information
mmarchetti committed Oct 26, 2023
1 parent 4180b83 commit a3fac3e
Show file tree
Hide file tree
Showing 2 changed files with 629 additions and 0 deletions.
107 changes: 107 additions & 0 deletions schema/example.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@
{
// URL to the schema definition, which we should make public.
"$schema": "./posit-publishing-schema-v3.json",
"type": "quarto-static",
"entrypoint": "report.qmd",

// name or id can be used to specify a target deployment to update.
// name can be used for initial deployment as well as updates.
// id can only be used for updates once the content has been deployed.
"name": "quarterly-sales-report-by-region",
"id": "de2e7bdb-b085-401e-a65c-443e40009749",

// Is this Connect-specific?
"custom_url": "/reports/quarterly-sales/",

// These metadata fields are purely for human consumption.
"title": "Regional Quarterly Sales Report",
"description": "This is the quarterly sales report, broken down by region.",
"author": {
"name": "Michael Marchetti",
"email": "[email protected]",
"username": "mmarchetti",
"organization": "Posit, PBC"
},
// Arbitrary string tags. On Connect, only admins can create tags,
// and tags can be nested (e.g. "sales,reports,quarterly" is a
// single tag 3 levels deep in the tag tree). The example below
// is 3 separate top level tags.
"tags": [
"sales",
"quarterly",
"regional"
],
// List of (relative) file paths. If constructing a bundle to upload,
// these files must be included. For git deployments, the server
// will expect (required) that these files be present in the repo.
// Unlike manifest v1, there are no checksums, since those require
// updating this file whenever other files change, and we'd prefer
// to write this once and commit it.
"files": [
"report.qmd",
"_quarto.yml",
"model.py",
"requirements.txt",
"weights/*.hdf5"
],
"dependencies": {
"python": {
"version": "3.11.3",
"package_file": "requirements.txt",
"package_manager": "pip"
},
"r": {
"version": "4.3.1",
"package_file": "renv.lock",
"package_manager": "packrat"
},
"quarto": {
"version": "1.4"
}
},
"environment": {
"API_URL": "https://example.com/api",
// secret value, will be pulled from the environment when deploying through CLI,
// must be set at the server if deploying through git.
"API_KEY": null
},
"schedule": {
// Only valid for reports, not for apps.
// iCalendar spec: https://icalendar.org/iCalendar-RFC-5545/3-8-5-3-recurrence-rule.html
"start": "2023-10-25T08:00:00Z",
"recurrence": "FREQ=MONTHLY;INTERVAL=3"
},
"connect": {
"access": {
"type": "logged-in",
"run_as": "rstudio-connect",
"run_as_current_user": false
},
"runtime": {
// Might some of these apply beyond Connect? For example, init_timeout
// tells the server how long this app might take to start up.
"connection_timeout": 5,
"read_timeout": 30,
"init_timeout": 60,
"idle_timeout": 120,
"max_processes": 5,
"min_processes": 1,
"max_conns_per_process": 50,
"load_factor": 0.5
},
"kubernetes": {
// Will Posit Cloud Connect be containerized? If so, will it support
// image_name, cpu_limit, memory_limit, and/or gpu settings?
"amd_gpu_limit": 0,
"cpu_limit": 1,
"cpu_request": 0.5,
"image_name": "posit/connect-runtime-python3.11-r4.3",
"memory_limit": "100000000",
"memory_request": "20000000",
"nvidia_gpu_limit": 0,
"service_account_name": "k8s-runner",
"r_environment_management": true,
"py_environment_management": true
}
}
}
Loading

0 comments on commit a3fac3e

Please sign in to comment.