v100 nas test
This commit is contained in:
parent
bc48154e5d
commit
d73ea95ab0
|
|
@ -0,0 +1,5 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
resources:
|
||||
- tf.yaml
|
||||
|
||||
|
|
@ -0,0 +1,68 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
spec:
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
resources:
|
||||
requests:
|
||||
storage: 1Gi
|
||||
storageClassName: user-nas
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: tf-notebook
|
||||
labels:
|
||||
workload-name: customer3
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: tf-notebook
|
||||
workload-name: customer3
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: tf-notebook
|
||||
workload-name: customer3
|
||||
spec:
|
||||
nodeSelector:
|
||||
nodegroup: v100
|
||||
containers:
|
||||
- name: tf-notebook
|
||||
image: tensorflow/tensorflow:2.16.2-gpu-jupyter
|
||||
resources:
|
||||
limits:
|
||||
cpu: "4"
|
||||
memory: 16Gi
|
||||
nvidia.com/gpu: 1
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
name: notebook
|
||||
volumeMounts:
|
||||
- name: notebook-storage
|
||||
mountPath: /sample
|
||||
volumes:
|
||||
- name: notebook-storage
|
||||
persistentVolumeClaim:
|
||||
claimName: tf-notebook-pvc
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: tf-notebook
|
||||
labels:
|
||||
app: tf-notebook
|
||||
workload-name: customer3
|
||||
spec:
|
||||
type: ClusterIP
|
||||
ports:
|
||||
- port: 80
|
||||
name: http
|
||||
targetPort: 8888
|
||||
selector:
|
||||
app: tf-notebook
|
||||
workload-name: customer3
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
resources:
|
||||
- ../../base
|
||||
|
||||
namePrefix: a1-
|
||||
namespace: org1
|
||||
|
||||
|
||||
patches:
|
||||
- path: patch-pvc.yaml
|
||||
target:
|
||||
kind: PersistentVolumeClaim
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
spec:
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
resources:
|
||||
- ../../base
|
||||
|
||||
namePrefix: a2-
|
||||
namespace: org1
|
||||
|
||||
|
||||
patches:
|
||||
- path: patch-pvc.yaml
|
||||
target:
|
||||
kind: PersistentVolumeClaim
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
|
|
@ -0,0 +1,54 @@
|
|||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: tf-notebook
|
||||
spec:
|
||||
replicas: 2
|
||||
selector:
|
||||
matchLabels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
spec:
|
||||
nodeSelector:
|
||||
nodegroup: gpu
|
||||
containers:
|
||||
- name: tf-notebook
|
||||
image: tensorflow/tensorflow:2.16.2-gpu-jupyter
|
||||
resources:
|
||||
limits:
|
||||
cpu: "4"
|
||||
memory: 16Gi
|
||||
nvidia.com/gpu: 2
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
name: notebook
|
||||
volumeMounts:
|
||||
- name: notebook-storage
|
||||
mountPath: /sample
|
||||
volumes:
|
||||
- name: notebook-storage
|
||||
persistentVolumeClaim:
|
||||
claimName: tf-notebook-pvc
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: tf-notebook
|
||||
labels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
spec:
|
||||
type: ClusterIP
|
||||
ports:
|
||||
- port: 80
|
||||
name: http
|
||||
targetPort: 8888
|
||||
selector:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
spec:
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: a1-tf-notebook-pvc
|
||||
namespace: org2
|
||||
spec:
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
storageClassName: nfs-client
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: a1-tf-notebook
|
||||
namespace: org2
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: tf-notebook
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: tf-notebook
|
||||
spec:
|
||||
containers:
|
||||
- image: tensorflow/tensorflow:2.16.2-gpu-jupyter
|
||||
name: tf-notebook
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
name: notebook
|
||||
resources:
|
||||
limits:
|
||||
nvidia.com/gpu: 1
|
||||
volumeMounts:
|
||||
- mountPath: /sample
|
||||
name: notebook-storage
|
||||
nodeSelector:
|
||||
nodegroup: gpu
|
||||
volumes:
|
||||
- name: notebook-storage
|
||||
persistentVolumeClaim:
|
||||
claimName: a1-tf-notebook-pvc
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
resources:
|
||||
- ../../base
|
||||
|
||||
namePrefix: a3-
|
||||
namespace: org2
|
||||
|
||||
|
||||
patches:
|
||||
- path: patch-pvc.yaml
|
||||
target:
|
||||
kind: PersistentVolumeClaim
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
|
|
@ -0,0 +1,54 @@
|
|||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: tf-notebook
|
||||
spec:
|
||||
replicas: 2
|
||||
selector:
|
||||
matchLabels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
spec:
|
||||
nodeSelector:
|
||||
nodegroup: gpu
|
||||
containers:
|
||||
- name: tf-notebook
|
||||
image: tensorflow/tensorflow:2.16.2-gpu-jupyter
|
||||
resources:
|
||||
limits:
|
||||
cpu: "4"
|
||||
memory: 16Gi
|
||||
nvidia.com/gpu: 2
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
name: notebook
|
||||
volumeMounts:
|
||||
- name: notebook-storage
|
||||
mountPath: /sample
|
||||
volumes:
|
||||
- name: notebook-storage
|
||||
persistentVolumeClaim:
|
||||
claimName: tf-notebook-pvc
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: tf-notebook
|
||||
labels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
spec:
|
||||
type: ClusterIP
|
||||
ports:
|
||||
- port: 80
|
||||
name: http
|
||||
targetPort: 8888
|
||||
selector:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
spec:
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: a1-tf-notebook-pvc
|
||||
namespace: org2
|
||||
spec:
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
storageClassName: nfs-client
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: a1-tf-notebook
|
||||
namespace: org2
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: tf-notebook
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: tf-notebook
|
||||
spec:
|
||||
containers:
|
||||
- image: tensorflow/tensorflow:2.16.2-gpu-jupyter
|
||||
name: tf-notebook
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
name: notebook
|
||||
resources:
|
||||
limits:
|
||||
nvidia.com/gpu: 1
|
||||
volumeMounts:
|
||||
- mountPath: /sample
|
||||
name: notebook-storage
|
||||
nodeSelector:
|
||||
nodegroup: gpu
|
||||
volumes:
|
||||
- name: notebook-storage
|
||||
persistentVolumeClaim:
|
||||
claimName: a1-tf-notebook-pvc
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
resources:
|
||||
- ../../base
|
||||
|
||||
namePrefix: a4-
|
||||
namespace: org2
|
||||
|
||||
|
||||
patches:
|
||||
- path: patch-pvc.yaml
|
||||
target:
|
||||
kind: PersistentVolumeClaim
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
|
|
@ -0,0 +1,54 @@
|
|||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: tf-notebook
|
||||
spec:
|
||||
replicas: 2
|
||||
selector:
|
||||
matchLabels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
spec:
|
||||
nodeSelector:
|
||||
nodegroup: gpu
|
||||
containers:
|
||||
- name: tf-notebook
|
||||
image: tensorflow/tensorflow:2.16.2-gpu-jupyter
|
||||
resources:
|
||||
limits:
|
||||
cpu: "4"
|
||||
memory: 16Gi
|
||||
nvidia.com/gpu: 2
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
name: notebook
|
||||
volumeMounts:
|
||||
- name: notebook-storage
|
||||
mountPath: /sample
|
||||
volumes:
|
||||
- name: notebook-storage
|
||||
persistentVolumeClaim:
|
||||
claimName: tf-notebook-pvc
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: tf-notebook
|
||||
labels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
spec:
|
||||
type: ClusterIP
|
||||
ports:
|
||||
- port: 80
|
||||
name: http
|
||||
targetPort: 8888
|
||||
selector:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
spec:
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: a1-tf-notebook-pvc
|
||||
namespace: org2
|
||||
spec:
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
storageClassName: nfs-client
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: a1-tf-notebook
|
||||
namespace: org2
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: tf-notebook
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: tf-notebook
|
||||
spec:
|
||||
containers:
|
||||
- image: tensorflow/tensorflow:2.16.2-gpu-jupyter
|
||||
name: tf-notebook
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
name: notebook
|
||||
resources:
|
||||
limits:
|
||||
nvidia.com/gpu: 1
|
||||
volumeMounts:
|
||||
- mountPath: /sample
|
||||
name: notebook-storage
|
||||
nodeSelector:
|
||||
nodegroup: gpu
|
||||
volumes:
|
||||
- name: notebook-storage
|
||||
persistentVolumeClaim:
|
||||
claimName: a1-tf-notebook-pvc
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
resources:
|
||||
- ../../base
|
||||
|
||||
namePrefix: a5-
|
||||
namespace: org3
|
||||
|
||||
|
||||
patches:
|
||||
- path: patch-pvc.yaml
|
||||
target:
|
||||
kind: PersistentVolumeClaim
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
|
|
@ -0,0 +1,54 @@
|
|||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: tf-notebook
|
||||
spec:
|
||||
replicas: 2
|
||||
selector:
|
||||
matchLabels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
spec:
|
||||
nodeSelector:
|
||||
nodegroup: gpu
|
||||
containers:
|
||||
- name: tf-notebook
|
||||
image: tensorflow/tensorflow:2.16.2-gpu-jupyter
|
||||
resources:
|
||||
limits:
|
||||
cpu: "4"
|
||||
memory: 16Gi
|
||||
nvidia.com/gpu: 2
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
name: notebook
|
||||
volumeMounts:
|
||||
- name: notebook-storage
|
||||
mountPath: /sample
|
||||
volumes:
|
||||
- name: notebook-storage
|
||||
persistentVolumeClaim:
|
||||
claimName: tf-notebook-pvc
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: tf-notebook
|
||||
labels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
spec:
|
||||
type: ClusterIP
|
||||
ports:
|
||||
- port: 80
|
||||
name: http
|
||||
targetPort: 8888
|
||||
selector:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
spec:
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: a1-tf-notebook-pvc
|
||||
namespace: org2
|
||||
spec:
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
storageClassName: nfs-client
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: a1-tf-notebook
|
||||
namespace: org2
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: tf-notebook
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: tf-notebook
|
||||
spec:
|
||||
containers:
|
||||
- image: tensorflow/tensorflow:2.16.2-gpu-jupyter
|
||||
name: tf-notebook
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
name: notebook
|
||||
resources:
|
||||
limits:
|
||||
nvidia.com/gpu: 1
|
||||
volumeMounts:
|
||||
- mountPath: /sample
|
||||
name: notebook-storage
|
||||
nodeSelector:
|
||||
nodegroup: gpu
|
||||
volumes:
|
||||
- name: notebook-storage
|
||||
persistentVolumeClaim:
|
||||
claimName: a1-tf-notebook-pvc
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
resources:
|
||||
- ../../base
|
||||
|
||||
namePrefix: a6-
|
||||
namespace: org3
|
||||
|
||||
|
||||
patches:
|
||||
- path: patch-pvc.yaml
|
||||
target:
|
||||
kind: PersistentVolumeClaim
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
|
|
@ -0,0 +1,54 @@
|
|||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: tf-notebook
|
||||
spec:
|
||||
replicas: 2
|
||||
selector:
|
||||
matchLabels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
spec:
|
||||
nodeSelector:
|
||||
nodegroup: gpu
|
||||
containers:
|
||||
- name: tf-notebook
|
||||
image: tensorflow/tensorflow:2.16.2-gpu-jupyter
|
||||
resources:
|
||||
limits:
|
||||
cpu: "4"
|
||||
memory: 16Gi
|
||||
nvidia.com/gpu: 2
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
name: notebook
|
||||
volumeMounts:
|
||||
- name: notebook-storage
|
||||
mountPath: /sample
|
||||
volumes:
|
||||
- name: notebook-storage
|
||||
persistentVolumeClaim:
|
||||
claimName: tf-notebook-pvc
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: tf-notebook
|
||||
labels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
spec:
|
||||
type: ClusterIP
|
||||
ports:
|
||||
- port: 80
|
||||
name: http
|
||||
targetPort: 8888
|
||||
selector:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
spec:
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: a1-tf-notebook-pvc
|
||||
namespace: org2
|
||||
spec:
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
storageClassName: nfs-client
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: a1-tf-notebook
|
||||
namespace: org2
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: tf-notebook
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: tf-notebook
|
||||
spec:
|
||||
containers:
|
||||
- image: tensorflow/tensorflow:2.16.2-gpu-jupyter
|
||||
name: tf-notebook
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
name: notebook
|
||||
resources:
|
||||
limits:
|
||||
nvidia.com/gpu: 1
|
||||
volumeMounts:
|
||||
- mountPath: /sample
|
||||
name: notebook-storage
|
||||
nodeSelector:
|
||||
nodegroup: gpu
|
||||
volumes:
|
||||
- name: notebook-storage
|
||||
persistentVolumeClaim:
|
||||
claimName: a1-tf-notebook-pvc
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
resources:
|
||||
- ../../base
|
||||
|
||||
namePrefix: a7-
|
||||
namespace: org1
|
||||
|
||||
|
||||
patches:
|
||||
- path: patch-pvc.yaml
|
||||
target:
|
||||
kind: PersistentVolumeClaim
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
|
|
@ -0,0 +1,54 @@
|
|||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: tf-notebook
|
||||
spec:
|
||||
replicas: 2
|
||||
selector:
|
||||
matchLabels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
spec:
|
||||
nodeSelector:
|
||||
nodegroup: gpu
|
||||
containers:
|
||||
- name: tf-notebook
|
||||
image: tensorflow/tensorflow:2.16.2-gpu-jupyter
|
||||
resources:
|
||||
limits:
|
||||
cpu: "4"
|
||||
memory: 16Gi
|
||||
nvidia.com/gpu: 2
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
name: notebook
|
||||
volumeMounts:
|
||||
- name: notebook-storage
|
||||
mountPath: /sample
|
||||
volumes:
|
||||
- name: notebook-storage
|
||||
persistentVolumeClaim:
|
||||
claimName: tf-notebook-pvc
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: tf-notebook
|
||||
labels:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
spec:
|
||||
type: ClusterIP
|
||||
ports:
|
||||
- port: 80
|
||||
name: http
|
||||
targetPort: 8888
|
||||
selector:
|
||||
app: tf-notebook
|
||||
user: user1
|
||||
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
spec:
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: a1-tf-notebook-pvc
|
||||
namespace: org2
|
||||
spec:
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
storageClassName: nfs-client
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: a1-tf-notebook
|
||||
namespace: org2
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: tf-notebook
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: tf-notebook
|
||||
spec:
|
||||
containers:
|
||||
- image: tensorflow/tensorflow:2.16.2-gpu-jupyter
|
||||
name: tf-notebook
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
name: notebook
|
||||
resources:
|
||||
limits:
|
||||
nvidia.com/gpu: 1
|
||||
volumeMounts:
|
||||
- mountPath: /sample
|
||||
name: notebook-storage
|
||||
nodeSelector:
|
||||
nodegroup: gpu
|
||||
volumes:
|
||||
- name: notebook-storage
|
||||
persistentVolumeClaim:
|
||||
claimName: a1-tf-notebook-pvc
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
resources:
|
||||
- ../../base
|
||||
|
||||
namePrefix: a1-
|
||||
namespace: org2
|
||||
|
||||
|
||||
patches:
|
||||
- path: patch-pvc.yaml
|
||||
target:
|
||||
kind: PersistentVolumeClaim
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: tf-notebook-pvc
|
||||
namespace: org1
|
||||
spec:
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
|
||||
|
|
@ -0,0 +1,46 @@
|
|||
apiVersion: v1
|
||||
kind: PersistentVolumeClaim
|
||||
metadata:
|
||||
name: a1-tf-notebook-pvc
|
||||
namespace: org2
|
||||
spec:
|
||||
accessModes:
|
||||
- ReadWriteOnce
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
storageClassName: nfs-client
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: a1-tf-notebook
|
||||
namespace: org2
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: tf-notebook
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: tf-notebook
|
||||
spec:
|
||||
containers:
|
||||
- image: tensorflow/tensorflow:2.16.2-gpu-jupyter
|
||||
name: tf-notebook
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
name: notebook
|
||||
resources:
|
||||
limits:
|
||||
nvidia.com/gpu: 1
|
||||
volumeMounts:
|
||||
- mountPath: /sample
|
||||
name: notebook-storage
|
||||
nodeSelector:
|
||||
nodegroup: gpu
|
||||
volumes:
|
||||
- name: notebook-storage
|
||||
persistentVolumeClaim:
|
||||
claimName: a1-tf-notebook-pvc
|
||||
Loading…
Reference in New Issue