gravitational / teleport

The easiest, and most secure way to access and protect all of your infrastructure.
https://goteleport.com
GNU Affero General Public License v3.0
17.35k stars 1.74k forks source link

Auto-generate the configuration reference #21318

Open ptgott opened 1 year ago

ptgott commented 1 year ago

Applies To

docs/pages/reference/config.mdx

Details

Let's auto-generate this page to ensure that it includes a comprehensive set of config fields.

Teleport loads the user's config file using the FileConfig type: https://github.com/gravitational/teleport/blob/25623c7eca94f5ba901b6234bb97ca8c029e7ed5/lib/config/fileconf.go#L63-L93

We can build the reference by traversing the fields of FileConfig using the various libraries that Go provides for working with ASTs.

Related Issues

https://github.com/gravitational/teleport/issues/13324

ptgott commented 1 year ago

Also see the comment here: https://github.com/gravitational/teleport/issues/13324#issuecomment-1376306657