Skip to content

Commit 1ee8a36

Browse files
committed
Merge branch 'task-get-podtemplate' of https://github.com/Snehadas2005/notebooks into task-get-podtemplate
2 parents 40d5c73 + f816fc1 commit 1ee8a36

6 files changed

Lines changed: 41 additions & 85 deletions

File tree

workspaces/backend/api/workspace_details_handler_test.go

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
/*
2+
Copyright 2024.
3+
4+
Licensed under the Apache License, Version 2.0 (the "License");
5+
you may not use this file except in compliance with the License.
6+
You may obtain a copy of the License at
7+
8+
http://www.apache.org/licenses/LICENSE-2.0
9+
10+
Unless required by applicable law or agreed to in writing, software
11+
distributed under the License is distributed on an "AS IS" BASIS,
12+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
See the License for the specific language governing permissions and
14+
limitations under the License.
15+
*/
16+
117
package api
218

319
import (

workspaces/backend/go.mod

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ require (
99
github.com/kubeflow/notebooks/workspaces/controller v0.0.0
1010
github.com/onsi/ginkgo/v2 v2.19.0
1111
github.com/onsi/gomega v1.33.1
12-
github.com/stretchr/testify v1.9.0
1312
github.com/swaggo/http-swagger/v2 v2.0.2
1413
github.com/swaggo/swag v1.16.6
1514
k8s.io/api v0.31.0
@@ -61,7 +60,6 @@ require (
6160
github.com/modern-go/reflect2 v1.0.2 // indirect
6261
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
6362
github.com/pkg/errors v0.9.1 // indirect
64-
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
6563
github.com/prometheus/client_golang v1.19.1 // indirect
6664
github.com/prometheus/client_model v0.6.1 // indirect
6765
github.com/prometheus/common v0.55.0 // indirect

workspaces/backend/internal/models/workspaces/types_details.go

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
/*
2+
Copyright 2024.
3+
4+
Licensed under the Apache License, Version 2.0 (the "License");
5+
you may not use this file except in compliance with the License.
6+
You may obtain a copy of the License at
7+
8+
http://www.apache.org/licenses/LICENSE-2.0
9+
10+
Unless required by applicable law or agreed to in writing, software
11+
distributed under the License is distributed on an "AS IS" BASIS,
12+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
See the License for the specific language governing permissions and
14+
limitations under the License.
15+
*/
16+
117
package workspaces
218

319
type WorkspaceDetails struct {

workspaces/backend/openapi/docs.go

Lines changed: 3 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -3283,50 +3283,22 @@ const docTemplate = `{
32833283
}
32843284
}
32853285
},
3286-
"github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailSecret": {
3287-
"type": "object",
3288-
"properties": {
3289-
"defaultMode": {
3290-
"type": "integer"
3291-
},
3292-
"mountPath": {
3293-
"type": "string"
3294-
},
3295-
"secretName": {
3296-
"type": "string"
3297-
}
3298-
}
3299-
},
3300-
"github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailVolume": {
3301-
"type": "object",
3302-
"properties": {
3303-
"mountPath": {
3304-
"type": "string"
3305-
},
3306-
"pvcName": {
3307-
"type": "string"
3308-
},
3309-
"readOnly": {
3310-
"type": "boolean"
3311-
}
3312-
}
3313-
},
33143286
"github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailVolumes": {
33153287
"type": "object",
33163288
"properties": {
33173289
"data": {
33183290
"type": "array",
33193291
"items": {
3320-
"$ref": "#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailVolume"
3292+
"$ref": "#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.PodVolumeInfo"
33213293
}
33223294
},
33233295
"home": {
3324-
"$ref": "#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailVolume"
3296+
"$ref": "#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.PodVolumeInfo"
33253297
},
33263298
"secrets": {
33273299
"type": "array",
33283300
"items": {
3329-
"$ref": "#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailSecret"
3301+
"$ref": "#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.PodSecretInfo"
33303302
}
33313303
}
33323304
}

workspaces/backend/openapi/swagger.json

Lines changed: 3 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -3281,50 +3281,22 @@
32813281
}
32823282
}
32833283
},
3284-
"github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailSecret": {
3285-
"type": "object",
3286-
"properties": {
3287-
"defaultMode": {
3288-
"type": "integer"
3289-
},
3290-
"mountPath": {
3291-
"type": "string"
3292-
},
3293-
"secretName": {
3294-
"type": "string"
3295-
}
3296-
}
3297-
},
3298-
"github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailVolume": {
3299-
"type": "object",
3300-
"properties": {
3301-
"mountPath": {
3302-
"type": "string"
3303-
},
3304-
"pvcName": {
3305-
"type": "string"
3306-
},
3307-
"readOnly": {
3308-
"type": "boolean"
3309-
}
3310-
}
3311-
},
33123284
"github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailVolumes": {
33133285
"type": "object",
33143286
"properties": {
33153287
"data": {
33163288
"type": "array",
33173289
"items": {
3318-
"$ref": "#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailVolume"
3290+
"$ref": "#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.PodVolumeInfo"
33193291
}
33203292
},
33213293
"home": {
3322-
"$ref": "#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailVolume"
3294+
"$ref": "#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.PodVolumeInfo"
33233295
},
33243296
"secrets": {
33253297
"type": "array",
33263298
"items": {
3327-
"$ref": "#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailSecret"
3299+
"$ref": "#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.PodSecretInfo"
33283300
}
33293301
}
33303302
}

workspaces/backend/openapi/swagger.yaml

Lines changed: 3 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -923,35 +923,17 @@ definitions:
923923
nodeName:
924924
type: string
925925
type: object
926-
github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailSecret:
927-
properties:
928-
defaultMode:
929-
type: integer
930-
mountPath:
931-
type: string
932-
secretName:
933-
type: string
934-
type: object
935-
github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailVolume:
936-
properties:
937-
mountPath:
938-
type: string
939-
pvcName:
940-
type: string
941-
readOnly:
942-
type: boolean
943-
type: object
944926
github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailVolumes:
945927
properties:
946928
data:
947929
items:
948-
$ref: '#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailVolume'
930+
$ref: '#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.PodVolumeInfo'
949931
type: array
950932
home:
951-
$ref: '#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailVolume'
933+
$ref: '#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.PodVolumeInfo'
952934
secrets:
953935
items:
954-
$ref: '#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetailSecret'
936+
$ref: '#/definitions/github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.PodSecretInfo'
955937
type: array
956938
type: object
957939
github_com_kubeflow_notebooks_workspaces_backend_internal_models_workspaces.WorkspaceDetails:

0 commit comments

Comments
 (0)