Commit be67e88
committed
feat: stub secrets API endpoints
This commit introduces a stub of the secrets management API to the Kubeflow Notebooks
workspace backend. It is intended to bootstrap API development but will require
follow up work to actually implement the business logic in line with the API proposal.
**API Endpoints Added:**
- GET /api/v1/secrets/{namespace} - List all secrets in namespace
- POST /api/v1/secrets/{namespace} - Create new secret
- GET /api/v1/secrets/{namespace}/{name} - Get specific secret details
- PUT /api/v1/secrets/{namespace}/{name} - Update existing secret
- DELETE /api/v1/secrets/{namespace}/{name} - Delete secret
**Key Features:**
- Complete data models for secret operations (create, update, list, detail)
- Comprehensive validation for secret keys and base64-encoded values
- Full Swagger/OpenAPI documentation generation
- Integration with existing authentication and authorization middleware
- Support for secret mounting information and audit trails
- Proper error handling and HTTP status codes
**Known Omissions:**
- No repository/ support for the stubbed API implementations
- API serves mocked data for all requests and does not actually interact k8s cluster
- Unit tests are very crude and presently rely on mocked data
- Missing business logic for majority of API handlers
This implementation provides the foundation for frontend integration to manage Kubernetes
secrets through the workspace interface.
Signed-off-by: Andy Stoneberg <astonebe@redhat.com>1 parent 5775b5d commit be67e88
File tree
12 files changed
+2501
-0
lines changed- workspaces/backend
- api
- internal
- helper
- models
- common
- secrets
- openapi
12 files changed
+2501
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
63 | 67 | | |
64 | 68 | | |
65 | 69 | | |
| |||
112 | 116 | | |
113 | 117 | | |
114 | 118 | | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
115 | 126 | | |
116 | 127 | | |
117 | 128 | | |
| |||
0 commit comments