This repository has been deprecated and is no longer supported! The Devfile 2.0 website and documentation has been moved to https://github.com/devfile/devfile-web/.
The generated JSON Schema documentation for the Devfile 2.x is available here: https://devfile.github.io/.
Devfile 2.1 development documentation
The repository has many versions of the documentation. Therefore, ensure you test the version of the documentation for your contribution.
- For the newest version, use the
masterbranch. - For an earlier version, use the
v<n>.<m>.xbranch wherenis the major version of the release, andmis the minor version. For example,v2.0.x. - When merging any changes for an earlier release, merge into the correct branch and not
master.
Build is the same for each branch.
On a local environment, use the same container and tools that all GitHub workflows use to:
- Generate the API reference HTML single-sourced from the API repository.
- Generate the static Antora website in the
builddirectory (including all inv2.*branches). - Start a preview server listening at http://0.0.0.0:4000.
- Validate the language on changed files.
- Validate the internal and external links.
- Validate the shell scripts.
- The
podmanordockertool is available.
- From the root of this repository, run:
$ git fetch --all
$ ./tools/runnerpreview.sh-
Watch the output for alert messages about language usage, broken links or errors in shell scripts.
-
Browse the results in the preview server at http://0.0.0.0:4000.
- Use the preview links visible in the pull requests comment.
https://github.com/devfile/api with the area/documentation label.
Each release, create a Git release, tag, and branch. The tag marks the initial release documentation.
The publication uses the branch. Add post-release updates to the branch. Further release work continues on the master branch.
To enable this, follow the following release process:
Create a branch specific to the release version. For example, if the release version is 2.0.0:
-
Prior to this process, update the API repository to copy a final version of the schema to a directory for that version. For example:
docs/modules/user-guide/attachments/jsonschemas/2.0.0/devfile.json -
Create the branch for the tag:
git fetch --all git checkout -b v2.0.x v2.0.0` -
Edit the
docs/antora.yamlfile to set theprod-ver,version, andprereleaseattributes:- For example if release is 2.0.0
asciidoc: attributes: prod-ver: 2.0 # [...] version: '2.0.0' prerelease: false
- For example if release is 2.0.0
-
Edit the
.gitignorefile to ignore the API reference files generated from the schema that are not for the release:docs/modules/user-guide/attachments/api-reference/next docs/modules/user-guide/attachments/api-reference/stable docs/modules/user-guide/examples/api-reference/next docs/modules/user-guide/examples/api-reference/stable -
Edit the
docs/modules/user-guide/partials/ref_api-reference.adocfile to pull the iframe and link from the newly generated directories.// [...] ++++ <iframe src="./_attachments/api-reference/2.0.0/index.html" style="border:none;width: 100%;min-height:50em;height:-webkit-fill-available;"></iframe> ++++ .Additional resources * link:{attachmentsdir}/jsonschemas/2.0.0/devfile.json[Download the current JSON Schema]``` -
Build the docs and verify all looks good.
-
Add the changes, commit the branch and push directly to the docs repo. (There is no merge required for this branch).
Now the master branch can be updated for the next release and to link the previous release docs
from the newly created v.2.0.x branch.
-
Modify 'docs/antora.yaml' to set the correct
versionandprod-vervalues. For example:asciidoc: attributes: prod-ver: 2.2 #[...] version: '2.2.0'
-
Build, test, commit and merge the changes
The .github/workflows/publication-builder.yml worklow:
- Builds the Antora website.
- Commits the artifact to the
publicationbranch. - Requests a build in the
devfile/landing-pagerepository that publishes the content of thepublicationbranch to the live website.
The .github/workflows/call-publication-builder.yml workflow calls the publication-builder.yml workflow on push on any release branch (master or v*).