Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sync RHODS 1.31 branch with v1.7 ODH branch #14

Merged
merged 2 commits into from
Aug 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 0 additions & 14 deletions components/notebook-controller/controllers/notebook_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -392,24 +392,10 @@ func generateStatefulSet(instance *v1beta1.Notebook) *appsv1.StatefulSet {
}

podSpec := &ss.Spec.Template.Spec
podSpec.Volumes = append(podSpec.Volumes, corev1.Volume{
Name: "shm",
VolumeSource: corev1.VolumeSource{
EmptyDir: &corev1.EmptyDirVolumeSource{
Medium: corev1.StorageMediumMemory,
},
},
})


container := &podSpec.Containers[0]
if container.WorkingDir == "" {
container.WorkingDir = "/home/jovyan"
}
container.VolumeMounts = append(container.VolumeMounts, corev1.VolumeMount{
Name: "shm",
MountPath: "/dev/shm",
})
if container.Ports == nil {
container.Ports = []corev1.ContainerPort{
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -439,7 +439,6 @@ var _ = Describe("The Openshift Notebook controller", func() {
"--upstream=http://localhost:8888",
"--upstream-ca=/var/run/secrets/kubernetes.io/serviceaccount/ca.crt",
"--email-domain=*",
"--skip-provider-button",
`--openshift-sar={"verb":"get","resource":"notebooks","resourceAPIGroup":"kubeflow.org",` +
`"resourceName":"` + Name + `","namespace":"$(NAMESPACE)"}`,
"--logout-url=https://example.notebook-url/notebook/" + Namespace + "/" + Name,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,10 @@ import (
"context"
"encoding/json"
"fmt"
configv1 "github.com/openshift/api/config/v1"
"net/http"

configv1 "github.com/openshift/api/config/v1"

nbv1 "github.com/kubeflow/kubeflow/components/notebook-controller/api/v1"
"github.com/kubeflow/kubeflow/components/notebook-controller/pkg/culler"
admissionv1 "k8s.io/api/admission/v1"
Expand Down Expand Up @@ -91,7 +92,6 @@ func InjectOAuthProxy(notebook *nbv1.Notebook, oauth OAuthConfig) error {
"--upstream=http://localhost:8888",
"--upstream-ca=/var/run/secrets/kubernetes.io/serviceaccount/ca.crt",
"--email-domain=*",
"--skip-provider-button",
`--openshift-sar={"verb":"get","resource":"notebooks","resourceAPIGroup":"kubeflow.org",` +
`"resourceName":"` + notebook.Name + `","namespace":"$(NAMESPACE)"}`,
},
Expand Down
Loading