|
@@ -38,7 +38,7 @@ func genParam(req *types.CreateJupyterInfo) map[string]interface{} {
|
|
|
|
|
|
}
|
|
}
|
|
if req.NodeSelector != "" {
|
|
if req.NodeSelector != "" {
|
|
- if strings.TrimSpace(req.NodeSelector) == "aihub-dag" {
|
|
|
|
|
|
+ if strings.HasPrefix(strings.TrimSpace(req.NodeSelector), "aihub-dag") {
|
|
settings = append(settings, fmt.Sprintf("jupyterlab.nodeSelector.aihub-dag=%s", req.NodeSelector))
|
|
settings = append(settings, fmt.Sprintf("jupyterlab.nodeSelector.aihub-dag=%s", req.NodeSelector))
|
|
|
|
|
|
} else {
|
|
} else {
|
|
@@ -55,6 +55,11 @@ func genParam(req *types.CreateJupyterInfo) map[string]interface{} {
|
|
settings = append(settings, fmt.Sprintf("jupyterlab.config.workspace=%s", req.Workspace))
|
|
settings = append(settings, fmt.Sprintf("jupyterlab.config.workspace=%s", req.Workspace))
|
|
settings = append(settings, fmt.Sprintf("jupyterlab.config.password=%s", req.Password))
|
|
settings = append(settings, fmt.Sprintf("jupyterlab.config.password=%s", req.Password))
|
|
|
|
|
|
|
|
+ if req.Cpu != "" && req.Memory != "" {
|
|
|
|
+ settings = append(settings, fmt.Sprintf("jupyterlab.resources.limits.cpu=%s", req.Cpu))
|
|
|
|
+ settings = append(settings, fmt.Sprintf("jupyterlab.resources.limits.memory=%s", req.Memory))
|
|
|
|
+ }
|
|
|
|
+
|
|
m := map[string]interface{}{
|
|
m := map[string]interface{}{
|
|
"dry_run": false,
|
|
"dry_run": false,
|
|
"create_namespace": false,
|
|
"create_namespace": false,
|