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: add docs about tutorials #506

Merged
merged 2 commits into from
Sep 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@
* [Release docs](./RELEASE.md)
* [Cluster connected docs](./CLUSTER.md)
* [Image tagging docs](./TAGGING.md)
* [Tutorials docs](./TUTORIALS.md)
62 changes: 62 additions & 0 deletions docs/TUTORIALS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# Tutorials docs

This docs contains informations related to the tutorials system used in the Playground

## tutorials.json

All tutorials are referenced in the [tutorials.json](../frontend/public/tutorials/tutorials.json) file.

This file contains an array of objects and defined the hierarchy and of the tutorials menu.

All properties can be inherited from the parent/overriden in the children.

| Property | Description |
|---|---|
| name | Menu item name |
| url | URL where referenced files are looked up (can be an internet URL or local path) |
| color | Menu item color |
| subgroups | Grouped children menu items |
| policies | Children menu items |
| path | File path |
| title | Menu item title |
| contextPath | Path to context file |
| oldResourceFile | Path to old resource file |
| clusterResourcesFile | Path to cluster resources file |
| exceptionsFile | Path to exception file |

Example:

```json
{
"name": "Other",
"url": "https://raw.githubusercontent.com/kyverno/policies/main/other",
"policies": [
{
"path": "a/add-certificates-volume",
"title": "Add Certificates as a Volume"
},
{
"path": "a/add-default-resources",
"title": "Add Default Resources"
},
{
"path": "a/add-labels",
"title": "Add Labels"
},
{
"path": "a/allowed-annotations",
"title": "Allowed Annotations"
},
{
"path": "b-d/check-env-vars",
"title": "Check Environment Variables"
},
{
"path": "rec-req/require-base-image",
"title": "Check Image Base"
}
]
}
```

Local files should be stored in the [tutorials folder](../frontend/public/tutorials/).
Loading