Skip to content

Commit

Permalink
Merge pull request #480 from cho4036/develop
Browse files Browse the repository at this point in the history
minor fix. fix url of kubeconfig
  • Loading branch information
ktkfree authored May 7, 2024
2 parents 091c91f + 79a0a0f commit d38123b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions internal/delivery/http/project.go
Original file line number Diff line number Diff line change
Expand Up @@ -1708,7 +1708,7 @@ func (p ProjectHandler) UnSetFavoriteProjectNamespace(w http.ResponseWriter, r *
// @Param organizationId path string true "Organization ID"
// @Param projectId path string true "Project ID"
// @Success 200 {object} domain.GetProjectKubeconfigResponse
// @Router /organizations/{organizationId}/projects/{projectId}/kubeconfig [get]
// @Router /organizations/{organizationId}/projects/{projectId}/kube-config [get]
// @Security JWT
func (p ProjectHandler) GetProjectKubeconfig(w http.ResponseWriter, r *http.Request) {
vars := mux.Vars(r)
Expand Down Expand Up @@ -1864,7 +1864,7 @@ func (p ProjectHandler) GetProjectNamespaceResourcesUsage(w http.ResponseWriter,
// @Param stackId path string true "Stack ID"
// @Param projectNamespace path string true "Project Namespace"
// @Success 200 {object} domain.GetProjectNamespaceKubeConfigResponse
// @Router /organizations/{organizationId}/projects/{projectId}/namespaces/{projectNamespace}/stacks/{stackId}/kubeconfig [get]
// @Router /organizations/{organizationId}/projects/{projectId}/namespaces/{projectNamespace}/stacks/{stackId}/kube-config [get]
// @Security JWT
func (p ProjectHandler) GetProjectNamespaceKubeconfig(w http.ResponseWriter, r *http.Request) {
vars := mux.Vars(r)
Expand Down
4 changes: 2 additions & 2 deletions internal/route/route.go
Original file line number Diff line number Diff line change
Expand Up @@ -289,8 +289,8 @@ func SetupRouter(db *gorm.DB, argoClient argowf.ArgoClient, kc keycloak.IKeycloa
r.Handle(API_PREFIX+API_VERSION+"/organizations/{organizationId}/projects/{projectId}/namespaces/{projectNamespace}/stacks/{stackId}", customMiddleware.Handle(internalApi.GetProjectNamespace, http.HandlerFunc(projectHandler.GetProjectNamespace))).Methods(http.MethodGet)
r.Handle(API_PREFIX+API_VERSION+"/organizations/{organizationId}/projects/{projectId}/namespaces/{projectNamespace}/stacks/{stackId}", customMiddleware.Handle(internalApi.UpdateProjectNamespace, http.HandlerFunc(projectHandler.UpdateProjectNamespace))).Methods(http.MethodPut)
r.Handle(API_PREFIX+API_VERSION+"/organizations/{organizationId}/projects/{projectId}/namespaces/{projectNamespace}/stacks/{stackId}", customMiddleware.Handle(internalApi.DeleteProjectNamespace, http.HandlerFunc(projectHandler.DeleteProjectNamespace))).Methods(http.MethodDelete)
r.Handle(API_PREFIX+API_VERSION+"/organizations/{organizationId}/projects/{projectId}/namespaces/{projectNamespace}/stacks/{stackId}/kubeconfig", customMiddleware.Handle(internalApi.GetProjectNamespaceKubeconfig, http.HandlerFunc(projectHandler.GetProjectNamespaceKubeconfig))).Methods(http.MethodGet)
r.Handle(API_PREFIX+API_VERSION+"/organizations/{organizationId}/projects/{projectId}/kubeconfig", customMiddleware.Handle(internalApi.GetProjectKubeconfig, http.HandlerFunc(projectHandler.GetProjectKubeconfig))).Methods(http.MethodGet)
r.Handle(API_PREFIX+API_VERSION+"/organizations/{organizationId}/projects/{projectId}/namespaces/{projectNamespace}/stacks/{stackId}/kube-config", customMiddleware.Handle(internalApi.GetProjectNamespaceKubeconfig, http.HandlerFunc(projectHandler.GetProjectNamespaceKubeconfig))).Methods(http.MethodGet)
r.Handle(API_PREFIX+API_VERSION+"/organizations/{organizationId}/projects/{projectId}/kube-config", customMiddleware.Handle(internalApi.GetProjectKubeconfig, http.HandlerFunc(projectHandler.GetProjectKubeconfig))).Methods(http.MethodGet)

auditHandler := delivery.NewAuditHandler(usecaseFactory)
r.Handle(API_PREFIX+API_VERSION+"/admin/audits", customMiddleware.Handle(internalApi.GetAudits, http.HandlerFunc(auditHandler.GetAudits))).Methods(http.MethodGet)
Expand Down

0 comments on commit d38123b

Please sign in to comment.