swagger-operator
2.5K
A Kubernetes operator that automatically discovers services annotated with OpenAPI/Swagger documentation and aggregates their documentation in a single UI.
You can install the Swagger Operator easily using the Helm Chart available on Docker Hub:
helm install swagger oci://registry-1.docker.io/ziuloliveira/swagger-operator --version <DESIRED_VERSION>-chart
Replace <DESIRED_VERSION> with the desired release version.
If you prefer, clone the repository for customization or local development:
git clone https://github.com/ziuloliveira/swagger-operator.git
cd swagger-operator
Add the following annotation to your Kubernetes services:
metadata:
annotations:
swagger-operator-path: "/openapi.json" # Path to your OpenAPI spec
swagger-operator-name: "My Service" # (Optional) Display name
swagger-operator-port: "8080" # (Optional) Service port
swagger-operator-header: |
Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=
X-Custom-Header: my-value
Another-Header: another-value
# (Optional) Extra headers
Expose the Operator (default port: 80) and access / to see the aggregated documentation.
SWAGGER_OPERATOR_PATH_KEY (default: swagger-operator-path)SWAGGER_OPERATOR_NAME_KEY (default: swagger-operator-name)SWAGGER_OPERATOR_PORT_KEY (default: swagger-operator-port)SWAGGER_OPERATOR_HEADER_KEY (default: swagger-operator-header)TITLE (default: API Documentation)MIT License
Made with ❤️ by Luiz Oliveira
Content type
Image
Digest
sha256:0611ef539…
Size
96 MB
Last updated
about 1 year ago
docker pull ziuloliveira/swagger-operator:0.4.0