File tree Expand file tree Collapse file tree 10 files changed +56
-73
lines changed Expand file tree Collapse file tree 10 files changed +56
-73
lines changed Original file line number Diff line number Diff line change 11# Image URL to use all building/pushing image targets
2- IMG ?= nbv2 -backend:latest
2+ IMG ?= nb -backend:latest
33# ENVTEST_K8S_VERSION refers to the version of kubebuilder assets to be downloaded by envtest binary.
44ENVTEST_K8S_VERSION = 1.31.0
55
@@ -155,12 +155,12 @@ $(GOLANGCI_LINT): $(LOCALBIN)
155155
156156.PHONY : deploy
157157deploy : kustomize # # Deploy backend to the K8s cluster specified in ~/.kube/config.
158- cd config/default && $(KUSTOMIZE ) edit set image nbv2 -backend=${IMG}
159- $(KUSTOMIZE ) build config/default | $(KUBECTL ) apply -f -
158+ cd manifests/kustomize/base && $(KUSTOMIZE ) edit set image nb -backend=${IMG}
159+ $(KUSTOMIZE ) build manifests/kustomize/base | $(KUBECTL ) apply -f -
160160
161161.PHONY : undeploy
162162undeploy : kustomize # # Undeploy backend from the K8s cluster specified in ~/.kube/config.
163- $(KUSTOMIZE ) build config/default | $(KUBECTL ) delete --ignore-not-found=true -f -
163+ $(KUSTOMIZE ) build manifests/kustomize/base | $(KUBECTL ) delete --ignore-not-found=true -f -
164164
165165
166166# #@ Dependencies
Load Diff This file was deleted.
Load Diff This file was deleted.
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 11apiVersion : apps/v1
22kind : Deployment
33metadata :
4- name : nbv2-backend
5- namespace : backend-system
6- labels :
7- app : nbv2-backend
8- app.kubernetes.io/component : backend
9- app.kubernetes.io/managed-by : kustomize
4+ name : backend
105spec :
116 replicas : 1
7+ selector :
8+ matchLabels : {}
129 strategy :
1310 type : RollingUpdate
1411 rollingUpdate :
1512 maxUnavailable : 0
1613 maxSurge : 1
17- selector :
18- matchLabels :
19- app : nbv2-backend
20- app.kubernetes.io/component : backend
21- app.kubernetes.io/managed-by : kustomize
2214 template :
2315 metadata :
24- labels :
25- app : nbv2-backend
26- app.kubernetes.io/component : backend
27- app.kubernetes.io/managed-by : kustomize
16+ labels : {}
2817 spec :
29- serviceAccountName : nbv2- backend
18+ serviceAccountName : backend
3019 securityContext :
3120 runAsNonRoot : true
3221 terminationGracePeriodSeconds : 30
3322 containers :
34- - name : nbv2 -backend
35- image : nbv2 -backend
23+ - name : nb -backend
24+ image : nb -backend
3625 imagePullPolicy : IfNotPresent
3726 securityContext :
3827 allowPrivilegeEscalation : false
3928 capabilities :
4029 drop :
4130 - " ALL"
4231 ports :
43- - containerPort : 4000
32+ - name : http-backend
33+ containerPort : 4000
4434 env :
4535 - name : PORT
4636 value : " 4000"
4737 resources :
4838 limits :
49- cpu : 500m
50- memory : 256Mi
39+ cpu : 1
40+ memory : 1Gi
5141 requests :
5242 cpu : 100m
53- memory : 128Mi
43+ memory : 512Mi
5444 livenessProbe :
5545 httpGet :
5646 path : /api/v1/healthcheck
57- port : 4000
47+ port : http-backend
5848 scheme : HTTP
5949 initialDelaySeconds : 30
6050 periodSeconds : 20
6454 readinessProbe :
6555 httpGet :
6656 path : /api/v1/healthcheck
67- port : 4000
57+ port : http-backend
6858 scheme : HTTP
6959 initialDelaySeconds : 10
7060 periodSeconds : 10
Original file line number Diff line number Diff line change 1+ apiVersion : kustomize.config.k8s.io/v1beta1
2+ kind : Kustomization
3+
4+ namespace : kubeflow-system
5+ namePrefix : nb-
6+
7+ resources :
8+ - service_account.yaml
9+ - rbac.yaml
10+ - service.yaml
11+ - deployment.yaml
12+
13+ images :
14+ - name : nb-backend
15+
16+ labels :
17+ - includeSelectors : true
18+ pairs :
19+ app.kubernetes.io/name : kubeflow-notebooks
20+ app.kubernetes.io/component : backend
21+ app.kubernetes.io/managed-by : kustomize
Original file line number Diff line number Diff line change @@ -27,5 +27,5 @@ roleRef:
2727 name : backend-clusterrole
2828subjects :
2929- kind : ServiceAccount
30- name : nbv2 -backend
31- namespace : backend -system
30+ name : nb -backend
31+ namespace : kubeflow -system
Original file line number Diff line number Diff line change 1+ apiVersion : v1
2+ kind : Service
3+ metadata :
4+ name : backend
5+ spec :
6+ selector : {}
7+ ports :
8+ - name : http-backend
9+ port : 4000
10+ targetPort : http-backend
11+ type : ClusterIP
Original file line number Diff line number Diff line change 1+ apiVersion : v1
2+ kind : ServiceAccount
3+ metadata :
4+ name : backend
You can’t perform that action at this time.
0 commit comments