We have an Openshift environment on our company.
We're trying to maximize the resources between our data scientists using jupyterhub.
Is there an option for assigning more resources dynamicly per demand (if there are free resources avaliable).
You can take a look at setting resource restrictions. (Quite counterintuitive, I agree).
In Kubernetes (and therefore in OpenShift) you can set resource requests
and limits
.
Resource requests
are the minimum a pod is guaranteed from the scheduler on the node it runs on. Resource Limits
on the other hand give you the capability to allow your pod to exceed its requested resources up to the specified limit.
What is the difference between not setting resource requests
and limits
vs setting them?
requests
and limits
limits
specifiedrequests
requests
and limits
requests
requests
and limits
In the end it should look something like this
apiVersion: v1
kind: Pod
spec:
containers:
- image: openshift/hello-openshift
name: hello-openshift
resources:
requests:
cpu: 100m
memory: 200Mi
ephemeral-storage: 1Gi
limits:
cpu: 200m
memory: 400Mi
ephemeral-storage: 2Gi
Additional information can be found here