-
Notifications
You must be signed in to change notification settings - Fork 40k
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
Generate API documentation for Kubernetes using Swagger #9097
Comments
We don't set |
Swagger 1.2 and 2.0 don't support TRACE - OAI/OpenAPI-Specification#325 |
Will have an example of the output shortly so you can see what it looks like. |
Yes this would be great (@MikeJeffrey and I recently discussed the need for this)! |
swagger2markup can also inline descriptions - that was used to get http://docs.openshift.org/latest/rest_api/kubernetes_v1.html#v1-persistentvolumeclaim |
Cool. Inlined from where? |
Directory structure - the generator looks for a file in a directory that corresponds to the name of the object or the name of the topic. It slurps in the asciidoc file and then generates the rest of the structure.
|
@smarterclayton does Markdown get automatically generated too (along with the AsciiDoc you use)? Im working on moving our user doc into GitHub pages and would like a copy of the API in Markdown. |
swagger2markup can output to Markdown. Asciidoc is the default. ----- Original Message -----
|
Any progress on this? |
Will open a pull next week when I get back from PTO |
We're doing this now. @caesarxuchao @nikhiljindal @RichieEscarez Anything we should fork off this issue before closing? |
I don't have more issues. |
I think the inconsistency between the GitHub repo and the Kubernetes.io versions of the API should be resolved. Issue: From in the Github repo, the raw versions of these API files get inconsistently displayed in a different color. Aside from the color and font differences between our two sources, the header in both files is also different (path vs. operations). Possible solutions:
|
I don't know if this is necessary, they are two different websites, people won't expect the format to be the same.
Good catch, this could be fixed by adding a line in https://github.com/kubernetes/kubernetes/blob/master/hack/gen-swagger-doc/gen-swagger-docs.sh and update the container image. Sorry I don't have time to do that this week. [update] |
@nikhiljindal We should fork another issue to track all of the swagger problems. |
Re: @caesarxuchao fixed the page title mismatch in #15040 |
There is also: #15343 |
What's left to do here? |
There are no big problems, but several enhancements nice to have. The left issues from smarterclayton's first comment
|
This was done by many people. |
I'm in the process of generating AsciiDoc / Markdown from swagger specs. General goals:
Primary angle of attack is https://github.com/RobWin/swagger2markup
Issues encountered
map[string]interface{}
. Also, the return type should be versionedObject[]...
in the swagger serialization format.The text was updated successfully, but these errors were encountered: