Skip to content

Commit 00d82c7

Browse files
thesuperzapperandyatmiami
authored andcommitted
mathew: 1
Signed-off-by: Mathew Wicks <5735406+thesuperzapper@users.noreply.github.com> Signed-off-by: Andy Stoneberg <astonebe@redhat.com>
1 parent 0fa87a6 commit 00d82c7

File tree

15 files changed

+88
-116
lines changed

15 files changed

+88
-116
lines changed

workspaces/backend/manifests/kustomize/base/kustomization.yaml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,9 @@ resources:
1313
labels:
1414
- includeSelectors: true
1515
pairs:
16-
app.kubernetes.io/component: api
16+
app.kubernetes.io/component: api
17+
18+
images:
19+
- name: workspaces-backend
20+
newName: ghcr.io/kubeflow/notebooks/workspaces-backend
21+
newTag: latest

workspaces/controller/internal/controller/workspacekind_controller.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ type WorkspaceKindReconciler struct {
4848
Scheme *runtime.Scheme
4949
}
5050

51-
// +kubebuilder:rbac:groups=kubeflow.org,resources=workspacekinds,verbs=get;list;watch;create;update;patch;delete
51+
// +kubebuilder:rbac:groups=kubeflow.org,resources=workspacekinds,verbs=create;delete;get;list;patch;update;watch
5252
// +kubebuilder:rbac:groups=kubeflow.org,resources=workspacekinds/status,verbs=get;update;patch
5353
// +kubebuilder:rbac:groups=kubeflow.org,resources=workspacekinds/finalizers,verbs=update
5454
// +kubebuilder:rbac:groups=kubeflow.org,resources=workspaces,verbs=get;list;watch

workspaces/controller/manifests/kustomize/base/crd/kustomization.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
apiVersion: kustomize.config.k8s.io/v1beta1
2+
kind: Kustomization
3+
14
# This kustomization.yaml is not intended to be run by itself,
25
# since it depends on service name and namespace that are out of this kustomize package.
36
# It should be run by manifests/kustomize/base
@@ -19,8 +22,5 @@ patches:
1922
- path: workspacekinds_cainjection_patch.yaml
2023
#+kubebuilder:scaffold:crdkustomizecainjectionpatch
2124

22-
# [WEBHOOK] To enable webhook, uncomment the following section
23-
# the following config is for teaching kustomize how to do kustomization for CRDs.
24-
2525
configurations:
2626
- kustomizeconfig.yaml

workspaces/controller/manifests/kustomize/base/kustomization.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
apiVersion: kustomize.config.k8s.io/v1beta1
2+
kind: Kustomization
3+
14
# Adds namespace to all resources.
25
namespace: kubeflow-workspaces
36

workspaces/controller/manifests/kustomize/base/manager/kustomization.yaml

Lines changed: 6 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,15 @@
11
apiVersion: kustomize.config.k8s.io/v1beta1
22
kind: Kustomization
3+
34
resources:
4-
- namespace.yaml
5+
- leader_election_role.yaml
6+
- leader_election_role_binding.yaml
57
- manager.yaml
6-
# All RBAC will be applied under this service account in
7-
# the deployment namespace. You may comment out this resource
8-
# if your manager will use a service account that exists at
9-
# runtime. Be sure to update RoleBinding and ClusterRoleBinding
10-
# subjects if changing service account names.
11-
- service_account.yaml
8+
- namespace.yaml
129
- role.yaml
1310
- role_binding.yaml
14-
- leader_election_role.yaml
15-
- leader_election_role_binding.yaml
16-
# For each CRD, "Editor" and "Viewer" roles are scaffolded by
17-
# default, aiding admins in cluster management. Those roles are
18-
# not used by the Project itself. You can comment the following lines
19-
# if you do not want those helpers be installed with your Project.
20-
- workspacekind_editor_role.yaml
21-
- workspacekind_viewer_role.yaml
22-
- workspace_editor_role.yaml
23-
- workspace_viewer_role.yaml
11+
- service_account.yaml
12+
- user_cluster_roles.yaml
2413

2514
labels:
2615
- includeSelectors: true
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
apiVersion: rbac.authorization.k8s.io/v1
2+
kind: ClusterRole
3+
metadata:
4+
name: kubeflow-workspaces-admin
5+
labels:
6+
rbac.authorization.kubeflow.org/aggregate-to-kubeflow-admin: "true"
7+
aggregationRule:
8+
clusterRoleSelectors:
9+
- matchLabels:
10+
rbac.authorization.kubeflow.org/aggregate-to-kubeflow-workspaces-admin: "true"
11+
rules: []
12+
---
13+
apiVersion: rbac.authorization.k8s.io/v1
14+
kind: ClusterRole
15+
metadata:
16+
name: kubeflow-workspaces-edit
17+
labels:
18+
rbac.authorization.kubeflow.org/aggregate-to-kubeflow-edit: "true"
19+
rbac.authorization.kubeflow.org/aggregate-to-kubeflow-workspaces-admin: "true"
20+
rules:
21+
- apiGroups:
22+
- kubeflow.org
23+
resources:
24+
- workspaces
25+
- workspaces/status
26+
verbs:
27+
- get
28+
- list
29+
- watch
30+
- create
31+
- delete
32+
- deletecollection
33+
- patch
34+
- update
35+
---
36+
apiVersion: rbac.authorization.k8s.io/v1
37+
kind: ClusterRole
38+
metadata:
39+
name: kubeflow-workspaces-view
40+
labels:
41+
rbac.authorization.kubeflow.org/aggregate-to-kubeflow-view: "true"
42+
rules:
43+
- apiGroups:
44+
- kubeflow.org
45+
resources:
46+
- workspaces
47+
- workspaces/status
48+
verbs:
49+
- get
50+
- list
51+
- watch

workspaces/controller/manifests/kustomize/base/manager/workspace_editor_role.yaml

Lines changed: 0 additions & 24 deletions
This file was deleted.

workspaces/controller/manifests/kustomize/base/manager/workspace_viewer_role.yaml

Lines changed: 0 additions & 20 deletions
This file was deleted.

workspaces/controller/manifests/kustomize/base/manager/workspacekind_editor_role.yaml

Lines changed: 0 additions & 24 deletions
This file was deleted.

workspaces/controller/manifests/kustomize/base/manager/workspacekind_viewer_role.yaml

Lines changed: 0 additions & 20 deletions
This file was deleted.

0 commit comments

Comments
 (0)