docs/9-platform-engineering/9.1.2-techdocs.md | |||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
TechDocs is Spotify's homegrown docs-like-code solution built directly into Backstage.
This solution is built on top of the docs like code approach. One central idea to this approach is that documentation should live with the code that it documents. This way if a developer can find either the code or its documentation, they can immediately find the other -- without having to go through any kind of rigmarole.
Backstage enables the docs like code approach by providing tools that can automatically generate an easy-to-navigate documentation website and associate it with one or more entities in a Software Catalog. This can be achieved in multiple ways -- for example, you can set up automated documentation with your Software Templates so that any Software Templates built on your Backstage instance will come with an associated docs website. You can also configure CI/CD to generate and publish TechDocs sites.
While TechDocs can be used in a variety of ways, we will start with something simple.
- If you haven't already, configure your Backstage instance to generate Software Catalog entities based on
catalog-info.yaml
files in a GitHub organization that you own. - Follow the Backstage docs to create and publish documentation for an entity in your Software Catalog.
- Verify that you can visit a "Documentation" section for your entity containing a nicely formatted docs page.
- Deep dive: Experiment with performing a top-level search of your Backstage instance for keywords contained in your docs. If this goes without a hitch, try stopping and restarting your instance, and immediately performing that search again. What happens, and why?
- What are some key aspects of the docs like code approach?
- How might an enterprise organization make use of TechDocs to manage documentation?